-
Notifications
You must be signed in to change notification settings - Fork 4
/
Makefile
49 lines (35 loc) · 1.48 KB
/
Makefile
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
# __ __
# __ ______ ____ ___ ____ _/ /____ ____ ____/ /
# / / / / __ \/ __ `__ \/ __ `/ __/ _ \/ __ \/ __ /
# / /_/ / /_/ / / / / / / /_/ / /_/ __/ /_/ / /_/ /
# \__, /\____/_/ /_/ /_/\__,_/\__/\___/\____/\__,_/
# /____ matthewdavis.io, holla!
#
include .make/Makefile.inc
VERSION ?= $(shell git rev-parse HEAD)
IMAGE ?= registry.gitlab.com/autobots.rocks/bots/autobot-docsbot:$(VERSION)
IMAGE_SECRET ?= docker-registry-autobot-docsbot
APP ?= autobot-docsbot
NS ?= default
PORT ?= 8080
GCE_DISK ?= autobot-docsbot
GCE_ZONE ?= us-central1-a
.PHONY: build
all: build push
build: ; docker build -t $(IMAGE) .
run: ; docker run -it $(IMAGE)
push: ; docker push $(IMAGE)
kubeme:
kubectl config use-context md
create-disk:
gcloud compute disks create $(GCE_DISK) --zone $(GCE_ZONE) --type pd-standard --size 10
delete-disk:
gcloud compute disks delete $(GCE_DISK) --zone $(GCE_ZONE)
build-local:
cd ~/workspace/work/autobots && make all PROJECT=autobot-module-docsbot
cd ~/workspace/work/autobots/autobot-docsbot && npm install @autobot/module-docsbot@latest
cd ~/workspace/work/autobots/autobot-docsbot && tsc && node dist/main.js
release:
cd ~/workspace/work/autobots && make all PROJECT=autobot-module-docsbot
cd ~/workspace/work/autobots/autobot-docsbot && npm install @autobot/module-docsbot@latest
cd ~/workspace/work/autobots/autobot-docsbot && git commit -am"$(MESSAGE)" && git push