Production image with own API_URL

This commit is contained in:
Aarni Halinen
2019-12-18 11:10:43 +02:00
parent 26358688e5
commit 0f9dac3565
3 changed files with 19 additions and 14 deletions
+3 -13
View File
@@ -32,18 +32,8 @@ sass:lint:
ts:build:
image: node:12
stage: build
only:
- master
script:
- API_URL=http://web.sik.party:8000/api npm run build
prod:build:
image: node:12
stage: build
only:
- production
script:
- API_URL=https://sika.sik.party/api npm run build
- npm run build
# test:unit:
# image: node:12
@@ -57,7 +47,7 @@ test:e2e:
only:
- master
script:
- npm run test:e2e
- API_URL=http://web.sik.party:8000/api npm run test:e2e
publish:
stage: publish
@@ -82,7 +72,7 @@ publish_prod:
script:
- docker info
- docker login -u gitlab-ci-token -p $CI_JOB_TOKEN $CI_REGISTRY
- docker build . -t "$IMAGE_NAME":prod
- docker build . -f Dockerfile.prod -t "$IMAGE_NAME":prod
- docker push "$IMAGE_NAME":prod
deploy_dev: