-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
46 lines (36 loc) · 1.07 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
.PHONY: up
up:
docker-compose -f ./environment/development.yml --env-file .env up -d --remove-orphans
.PHONY: build
build: files-copy
docker-compose -f ./environment/development.yml --env-file .env build
.PHONY: down
down:
docker-compose -f ./environment/development.yml down --remove-orphans
.PHONY: db-create
db-create:
docker exec -it graphql-db sh -c "bash /docker-entrypoint-initdb.d/createDB.sh"
.PHONY: sv-start
sv-start:
docker exec -it graphql-server sh -c "go run main.go"
.PHONY: sv-generate
sv-generate:
docker exec -it graphql-server sh -c "go generate main.go"
.PHONY: sv-build
sv-build:
docker exec -it graphql-server sh -c "go build main.go"
.PHONY: init-packages
init-packages:
docker exec -it graphql-server sh -c "go get -d -v ./..."
.PHONY: files-copy
files-copy:
cp ./config/env.dev .env
.PHONY: go-lint
go-lint:
docker exec -it graphql-server sh -c "golangci-lint run --fix --fast"
# postgres query
# \c graphql_db connect to db
# \dt list out all the tables
# go run github.com/99designs/gqlgen generate
# docker exec -it graphql-db sh -c "psql -l"
# wire