Skip to content

Commit 8ea94f2

Browse files
committed
refactor(ci): edit path of build script
1 parent 5add8a1 commit 8ea94f2

File tree

4 files changed

+13
-9
lines changed

4 files changed

+13
-9
lines changed

.gitlab-ci.yml

Lines changed: 9 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,8 @@ stages:
1111
build-dev:
1212
stage: build
1313
script:
14-
- TAG=dev sh ./scripts/build-push.sh
14+
- cat $ENV_FILE_DEV >> ./docker/.env
15+
- TAG=dev sh ./docker/scripts/build-push.sh
1516
only:
1617
- develop
1718
tags:
@@ -20,7 +21,8 @@ build-dev:
2021
build-stag:
2122
stage: build
2223
script:
23-
- TAG=stag sh ./scripts/build-push.sh
24+
- cat $ENV_FILE_STAG >> ./docker/.env
25+
- TAG=stag sh ./docker/scripts/build-push.sh
2426
only:
2527
- master
2628
tags:
@@ -29,7 +31,8 @@ build-stag:
2931
build-prod:
3032
stage: build
3133
script:
32-
- TAG=prod FRONTEND_ENV=production sh ./scripts/build-push.sh
34+
- cat $ENV_FILE_PROD >> ./docker/.env
35+
- TAG=prod sh ./docker/scripts/build-push.sh
3336
only:
3437
- production
3538
tags:
@@ -38,9 +41,10 @@ build-prod:
3841
deploy-dev:
3942
stage: deploy
4043
script:
44+
- cat $ENV_FILE_DEV >> ./docker/.env
4145
- >
4246
TAG=dev
43-
sh ./scripts/deploy.sh
47+
sh ./docker/scripts/deploy.sh
4448
environment:
4549
name: development
4650
only:
@@ -54,7 +58,7 @@ deploy-stag:
5458
script:
5559
- >
5660
TAG=stag
57-
sh ./scripts/deploy.sh
61+
sh ./docker/scripts/deploy.sh
5862
environment:
5963
name: staging
6064
only:

docker/scripts/build-push.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
set -e
55

66
TAG=${TAG?Variable not set} \
7-
sh ./scripts/build.sh
7+
sh ./docker/scripts/build.sh
88

9-
docker-compose -f docker-compose.yml push
9+
docker-compose -f ./docker/docker-compose.yml push

docker/scripts/build.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,5 +5,5 @@ set -e
55

66
TAG=${TAG?Variable not set} \
77
docker-compose \
8-
-f docker-compose.yml \
8+
-f ./docker/docker-compose.yml \
99
build

docker/scripts/deploy.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ set -e
55

66
TAG=${TAG?Variable not set} \
77
docker-compose \
8-
-f docker-compose.yml \
8+
-f ./docker/docker-compose.yml \
99
config > docker-stack.yml
1010

1111
docker-auto-labels docker-stack.yml

0 commit comments

Comments
 (0)