ng-tracker/.gitlab-ci.yml
2019-04-05 16:37:03 +04:00

45 lines
901 B
YAML

image: romanov73/is:ng-tracker-container
cache:
key: "$CI_PROJECT_ID"
paths:
- .gradle/
variables:
GRADLE_OPTS: "-Dorg.gradle.daemon=false"
before_script:
# - 'which ssh-agent || ( apt-get update -y && apt-get install openssh-client -y )'
# - apt-get install openjdk-8-jdk git -y
- eval $(ssh-agent -s)
- echo "$SSH_PRIVATE_KEY" | tr -d '\r' | ssh-add - > /dev/null
- mkdir -p ~/.ssh
- chmod 700 ~/.ssh
- git log --pretty="%cn;%cd;%s" > src/main/resources/commits.log
build:
stage: build
script: ./gradlew assemble
cache:
key: "$CI_PROJECT_ID"
policy: push
paths:
- build
- .gradle
deploy:
stage: deploy
script:
- sh deploy/gdccloud/deploy.sh
only:
- dev
cache:
key: "$CI_PROJECT_ID"
policy: pull
paths:
- build
- .gradle
environment:
name: staging
url: http://193.110.3.124:8080