-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.gitlab-ci.yml
23 lines (21 loc) · 957 Bytes
/
.gitlab-ci.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
stages:
- deploy
deploy development:
stage: deploy
tags:
- shell_runner
when: manual
before_script:
- docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY
script:
- sed -i "s|VITE_SUPERAPP_URL=.*|VITE_SUPERAPP_URL=${SUPERAPP_URL}|g" .env.example
- sed -i "s/VITE_SUPERAPP_TOKEN=.*/VITE_SUPERAPP_TOKEN=${SUPERAPP_TOKEN}/g" .env.example
- sed -i "s|VITE_TAG_QR_REFERENCE_CODE=.*|VITE_TAG_QR_REFERENCE_CODE=${TAG_QR_REFERENCE_CODE}|g" .env.example
- mv .env.example .env
- docker build --push
-t registry.macellan.net/aytekin/macellan-gate-screen:latest .
- ssh deploy@${SERVER_DEV_IP} "
docker login -u $CI_REGISTRY_USER -p $CI_REGISTRY_PASSWORD $CI_REGISTRY &&
docker pull registry.macellan.net/aytekin/macellan-gate-screen:latest &&
docker rm -f super-gate &&
docker run -d -p 5173:80 --name super-gate registry.macellan.net/aytekin/macellan-gate-screen:latest"