feat(infra): Add market prod (#8204)

market prod values
market prod values
This commit is contained in:
Aarushi
2024-09-27 10:08:01 +01:00
committed by GitHub
parent 1286a1b034
commit 31450fcb9c
6 changed files with 131 additions and 31 deletions

View File

@@ -1,7 +1,7 @@
apiVersion: cloud.google.com/v1
kind: BackendConfig
metadata:
name: {{ include "autogpt-market.fullname" . }}
name: {{ include "autogpt-market.fullname" . }}-backend-config
spec:
customRequestHeaders:
headers:

View File

@@ -41,7 +41,7 @@ spec:
imagePullPolicy: {{ .Values.image.pullPolicy }}
ports:
- name: http
containerPort: {{ .Values.service.port }}
containerPort: {{ .Values.service.targetPort }}
protocol: TCP
livenessProbe:
{{- toYaml .Values.livenessProbe | nindent 12 }}
@@ -53,15 +53,6 @@ spec:
volumeMounts:
{{- toYaml . | nindent 12 }}
{{- end }}
- name: cloud-sql-proxy
image: "{{ .Values.cloudSqlProxy.image.repository }}:{{ .Values.cloudSqlProxy.image.tag }}"
args:
- "--structured-logs"
{{- if .Values.cloudSqlProxy.usePrivateIp }}
- "--private-ip"
{{- end }}
- "--port={{ .Values.cloudSqlProxy.port }}"
- "{{ .Values.cloudSqlProxy.instanceConnectionName }}"
{{- with .Values.volumes }}
volumes:
{{- toYaml . | nindent 8 }}

View File

@@ -4,11 +4,15 @@ metadata:
name: {{ include "autogpt-market.fullname" . }}
labels:
{{- include "autogpt-market.labels" . | nindent 4 }}
{{- with .Values.service.annotations }}
annotations:
{{- toYaml . | nindent 4 }}
{{- end }}
spec:
type: {{ .Values.service.type }}
ports:
- port: {{ .Values.service.port }}
targetPort: http
targetPort: {{ .Values.service.targetPort }}
protocol: TCP
name: http
selector:

View File

@@ -12,11 +12,11 @@ serviceAccount:
service:
type: ClusterIP
port: 8000
targetPort: 8005
port: 8015
targetPort: 8015
annotations:
cloud.google.com/neg: '{"ingress": true}'
beta.cloud.google.com/backend-config: '{"default": "autogpt-market"}'
beta.cloud.google.com/backend-config: '{"default": "autogpt-market-backend-config"}'
ingress:
enabled: true
@@ -25,7 +25,7 @@ ingress:
kubernetes.io/ingress.class: gce
kubernetes.io/ingress.global-static-ip-name: "agpt-dev-agpt-market-ip"
networking.gke.io/managed-certificates: "autogpt-market-cert"
kubernetes.io/ingress.allow-http: "false"
networking.gke.io/v1beta1.FrontendConfig: "autogpt-market-frontend-config"
hosts:
- host: dev-market.agpt.co
paths:
@@ -34,12 +34,12 @@ ingress:
backend:
service:
name: autogpt-market
port: 8000
port: 8015
defaultBackend:
service:
name: autogpt-market
port:
number: 8000
number: 8015
resources:
requests:
@@ -52,7 +52,7 @@ resources:
livenessProbe:
httpGet:
path: /health
port: 8000
port: 8015
initialDelaySeconds: 60
periodSeconds: 20
timeoutSeconds: 10
@@ -60,7 +60,7 @@ livenessProbe:
readinessProbe:
httpGet:
path: /health
port: 8000
port: 8015
initialDelaySeconds: 60
periodSeconds: 20
timeoutSeconds: 10
@@ -95,9 +95,14 @@ cors:
env:
APP_ENV: "dev"
PYRO_HOST: "0.0.0.0"
ENABLE_AUTH: "true"
SUPABASE_JWT_SECRET: ""
SUPABASE_ANON_KEY: ""
SUPABASE_URL: ""
DATABASE_URL: ""
SENTRY_DSN: ""
SUPABASE_SERVICE_ROLE_KEY: ""
GITHUB_CLIENT_ID: ""
GITHUB_CLIENT_SECRET: ""
FRONTEND_BASE_URL: "https://dev-builder.agpt.co/"
SUPABASE_URL: "https://adfjtextkuilwuhzdjpf.supabase.co"
BACKEND_CORS_ALLOW_ORIGINS: "https://dev-builder.agpt.co"

View File

@@ -0,0 +1,109 @@
# prod values, overwrite base values as needed.
image:
repository: us-east1-docker.pkg.dev/agpt-prod/agpt-market-prod/agpt-market-prod
pullPolicy: Always
tag: "latest"
serviceAccount:
annotations:
iam.gke.io/gcp-service-account: "prod-agpt-market-sa@agpt-prod.iam.gserviceaccount.com"
name: "prod-agpt-market-sa"
service:
type: ClusterIP
port: 8015
targetPort: 8015
annotations:
cloud.google.com/neg: '{"ingress": true}'
beta.cloud.google.com/backend-config: '{"default": "autogpt-market-backend-config"}'
ingress:
enabled: true
className: "gce"
annotations:
kubernetes.io/ingress.class: gce
kubernetes.io/ingress.global-static-ip-name: "agpt-prod-agpt-market-ip"
networking.gke.io/managed-certificates: "autogpt-market-cert"
networking.gke.io/v1beta1.FrontendConfig: "autogpt-market-frontend-config"
hosts:
- host: platform.agpt.co
paths:
- path: /
pathType: Prefix
backend:
service:
name: autogpt-market
port: 8015
defaultBackend:
service:
name: autogpt-market
port:
number: 8015
resources:
requests:
cpu: 200m
memory: 1Gi
limits:
cpu: 2
memory: 2Gi
livenessProbe:
httpGet:
path: /health
port: 8015
initialDelaySeconds: 60
periodSeconds: 20
timeoutSeconds: 10
failureThreshold: 12
readinessProbe:
httpGet:
path: /health
port: 8015
initialDelaySeconds: 60
periodSeconds: 20
timeoutSeconds: 10
failureThreshold: 12
domain: "market.agpt.co"
cloudSqlProxy:
image:
repository: gcr.io/cloud-sql-connectors/cloud-sql-proxy
tag: 2.11.4
instanceConnectionName: "agpt-prod:us-central1:agpt-server-prod"
port: 5432
resources:
requests:
memory: "2Gi"
cpu: "1"
cors:
allowOrigin: "https://platform.agpt.co"
allowMethods:
- "GET"
- "POST"
- "PUT"
- "DELETE"
- "OPTIONS"
allowHeaders:
- "Content-Type"
- "Authorization"
maxAge: 3600
allowCredentials: true
env:
APP_ENV: "prod"
PYRO_HOST: "0.0.0.0"
ENABLE_AUTH: "true"
SUPABASE_JWT_SECRET: ""
DATABASE_URL: ""
SENTRY_DSN: ""
SUPABASE_SERVICE_ROLE_KEY: ""
GITHUB_CLIENT_ID: ""
GITHUB_CLIENT_SECRET: ""
FRONTEND_BASE_URL: "https://platform.agpt.co/"
SUPABASE_URL: "https://bgwpwdsxblryihinutbx.supabase.co"
BACKEND_CORS_ALLOW_ORIGINS: "https://platform.agpt.co"

View File

@@ -71,15 +71,6 @@ resources: {}
# cpu: 100m
# memory: 128Mi
livenessProbe:
httpGet:
path: /
port: http
readinessProbe:
httpGet:
path: /
port: http
autoscaling:
enabled: false
minReplicas: 1