-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathcloudbuild.yaml
41 lines (36 loc) · 1.34 KB
/
cloudbuild.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
steps:
# Pull the sweepai/sweep:latest image from Docker Hub (or wherever it resides)
- name: 'docker'
args: ['pull', 'sweepai/sweep:latest']
# Tag the pulled image for Google Container Registry (GCR)
- name: 'docker'
args: ['tag', 'sweepai/sweep:latest', 'gcr.io/$PROJECT_ID/sweep:latest']
# Push the image to GCR
- name: 'gcr.io/cloud-builders/docker'
args: ['push', 'gcr.io/$PROJECT_ID/sweep:latest']
# Deploy the image to Cloud Run
- name: 'gcr.io/cloud-builders/gcloud'
args: [
'beta',
'run',
'deploy',
'develop-up-sweep', # Replace with your desired Cloud Run service name
'--image', 'gcr.io/$PROJECT_ID/sweep:latest',
'--region', 'us-central1', # Replace with your desired region
'--platform', 'managed',
'--memory', '8Gi',
'--cpu', '4',
'--allow-unauthenticated', # Remove this line if you want authentication
'--port=8080',
'--vpc-connector',
'upmortem-sweep-connector',
'--set-env-vars=APP_ID=387016,
OPENAI_DO_HAVE_32K_MODEL_ACCESS=false,
SENTENCE_TRANSFORMERS_MODEL=sentence-transformers/all-MiniLM-L6-v2,
VECTOR_EMBEDDING_SOURCE=openai',
'--set-secrets=GITHUB_APP_PEM=GITHUB_APP_PEM:latest,
OPENAI_API_KEY=OPENAI_API_KEY:latest',
]
options:
logging: CLOUD_LOGGING_ONLY
env: ['PORT=8080']