FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
getting-started-python/optional-container-engine/Makefile at master · dpebot/getting-started-python · GitHub
dpebot
/
getting-started-python
Public
forked from
GoogleCloudPlatform/getting-started-python
Notifications
You must be signed in to change notification settings
Fork
4
Star
5
Code
Pull requests
0
Actions
Projects
Wiki
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Wiki
Security and quality
Insights
Expand file tree
Breadcrumbs
getting-started-python
/
optional-container-engine
/
Makefile
Copy path
More file actions
More file actions
Latest commit
History
History
History
50 lines (39 loc) · 1.24 KB
Breadcrumbs
getting-started-python
/
optional-container-engine
/
Makefile
Copy path
File metadata and controls
50 lines (39 loc) · 1.24 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
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
42
43
44
45
46
47
48
49
50
GCLOUD_PROJECT:
=
$(
shell
gcloud config list project --format="value(core.project)
")
.PHONY
: all
all
: deploy
.PHONY
: create-cluster
create-cluster
:
gcloud container clusters create bookshelf
\
--scope
"
cloud-platform
"
\
--num-nodes 2
gcloud container clusters get-credentials bookshelf
.PHONY
: create-bucket
create-bucket
:
gsutil mb gs://
$(
GCLOUD_PROJECT
)
gsutil
defacl
set
public-read
gs
://
$(
GCLOUD_PROJECT
)
.PHONY
: build
build
:
docker build -t gcr.io/
$(
GCLOUD_PROJECT
)
/bookshelf
.
.PHONY
: push
push
: build
gcloud docker push gcr.io/
$(
GCLOUD_PROJECT
)
/bookshelf
.PHONY
: template
template
:
sed -i
"
.tmpl
"
"
s/\[GCLOUD_PROJECT\]/
$(
GCLOUD_PROJECT
)
/g
"
bookshelf-frontend.yaml
sed -i
"
.tmpl
"
"
s/\[GCLOUD_PROJECT\]/
$(
GCLOUD_PROJECT
)
/g
"
bookshelf-worker.yaml
.PHONY
: create-service
create-service
:
kubectl create -f bookshelf-service.yaml
.PHONY
: deploy-frontend
deploy-frontend
: push template
kubectl create -f bookshelf-frontend.yaml
.PHONY
: deploy-worker
deploy-worker
: push template
kubectl create -f bookshelf-worker.yaml
.PHONY
: deploy
deploy
: deploy-frontend deploy-worker create-service
.PHONY
: delete
delete
:
-kubectl delete -f bookshelf-frontend.yaml
-kubectl delete -f bookshelf-worker.yaml
-kubectl delete -f bookshelf-frontend.yaml
Back
|
FazBrowse Home
|
New Git URL