Skip to content

Commit f8a58a0

Browse files
committed
deploy: add deployment configuration for a gotip playground instance
For now, just define GCP configuration. In a subsequent CL we should parameterize the playground UI to indicate that this is tip go. Updates golang/go#48517 Change-Id: I8a885126b95f60e02f46f7557cada2ec2e0b2882 Reviewed-on: https://go-review.googlesource.com/c/playground/+/362854 Trust: Robert Findley <rfindley@google.com> Run-TryBot: Robert Findley <rfindley@google.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Alexander Rakoczy <alex@golang.org>
1 parent d55b12a commit f8a58a0

File tree

4 files changed

+56
-19
lines changed

4 files changed

+56
-19
lines changed

app.gotip.yaml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
service: gotipplay
2+
includes:
3+
- playground.yaml

app.yaml

Lines changed: 2 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,20 +1,3 @@
11
service: play
2-
runtime: custom
3-
env: flex
4-
5-
network:
6-
name: projects/golang-org/global/networks/golang
7-
8-
resources:
9-
cpu: 2
10-
memory_gb: 2
11-
12-
automatic_scaling:
13-
min_num_instances: 5
14-
15-
readiness_check:
16-
path: "/_ah/health"
17-
check_interval_sec: 10
18-
19-
env_variables:
20-
MEMCACHED_ADDR: 'memcached-play-golang:11211'
2+
includes:
3+
- playground.yaml

deploy/deploy_gotip.json

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
{
2+
"steps": [
3+
{
4+
"name": "gcr.io/cloud-builders/docker",
5+
"entrypoint": "bash",
6+
"args": [
7+
"-c",
8+
"docker build --build-arg GO_VERSION=master -t gcr.io/$PROJECT_ID/playground-gotip ."
9+
]
10+
},
11+
{
12+
"name": "gcr.io/cloud-builders/docker",
13+
"args": [
14+
"push",
15+
"gcr.io/$PROJECT_ID/playground-gotip"
16+
]
17+
},
18+
{
19+
"name": "gcr.io/cloud-builders/gcloud",
20+
"args": [
21+
"app",
22+
"deploy",
23+
"app.gotip.yaml",
24+
"--project=$PROJECT_ID",
25+
"--image-url=gcr.io/$PROJECT_ID/playground-gotip:latest"
26+
]
27+
}
28+
],
29+
"timeout": "1800s"
30+
}

playground.yaml

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
# Shared configuration for playground App Engine instances.
2+
runtime: custom
3+
env: flex
4+
5+
network:
6+
name: projects/golang-org/global/networks/golang
7+
8+
resources:
9+
cpu: 2
10+
memory_gb: 2
11+
12+
automatic_scaling:
13+
min_num_instances: 5
14+
15+
readiness_check:
16+
path: "/_ah/health"
17+
check_interval_sec: 10
18+
19+
env_variables:
20+
MEMCACHED_ADDR: 'memcached-play-golang:11211'
21+

0 commit comments

Comments
 (0)