Skip to content
Snippets Groups Projects
Commit 123715fa authored by Wilson JALLET's avatar Wilson JALLET :money_with_wings:
Browse files

CI config update

parent 58d1dcd6
No related branches found
No related tags found
No related merge requests found
...@@ -18,6 +18,10 @@ stages: ...@@ -18,6 +18,10 @@ stages:
- test - test
- deploy - deploy
before_script:
- mkdir ~/.ssh
- eval $(ssh-agent -s)
### Jobs ### ### Jobs ###
# Install dependencies, compile the bundle.js, # Install dependencies, compile the bundle.js,
...@@ -29,14 +33,12 @@ build: ...@@ -29,14 +33,12 @@ build:
- npm run build - npm run build
- knex migrate:latest - knex migrate:latest
- knex seed:run - knex seed:run
only:
- master
artifacts: artifacts:
paths: paths:
- ldap_connexion_config.json - ldap_connexion_config.json
- build/ - build/
- node_modules/ - node_modules/
expire_in: 240 min expire_in: 240 min
tags: tags:
- database - database
- build - build
...@@ -51,12 +53,14 @@ test:lint: ...@@ -51,12 +53,14 @@ test:lint:
deploy_staging: deploy_staging:
stage: deploy stage: deploy
only:
- master
script: script:
- npm run build - npm run build
- ssh-add <(echo "$STAGING_PRIVATE_KEY") - ssh-add <(echo "$STAGING_PRIVATE_KEY")
- ssh -p22 sigma-dev@roued "mkdir -p /opt/sigma-back-dev - ssh -p 22 sigma-dev@roued "mkdir -p /opt/sigma-back-dev
- ssh -p22 sigma-dev@roued "rm -r /opt/sigma-back-dev/build" - ssh -p 22 sigma-dev@roued "rm -r /opt/sigma-back-dev/build"
- scp -p22 -r build/ sigma-dev@roued:/opt/sigma-back-dev/build - scp -p 22 -r build/ sigma-dev@roued:/opt/sigma-back-dev/build
environment: environment:
name: staging name: staging
url: http://129.104.210.10:3000 url: http://129.104.210.10:3000
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment