From c74aea6c3b2ae64c3d6654a3347538e9a35b0d49 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=B0=8F=E6=B5=B7?= Date: Fri, 17 Apr 2020 13:27:06 +0800 Subject: [PATCH] =?UTF-8?q?=E7=A7=BB=E9=99=A4gitlab=20ci?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .gitlab-ci.yml | 30 ------------------------------ 1 file changed, 30 deletions(-) delete mode 100644 .gitlab-ci.yml diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml deleted file mode 100644 index 9137476..0000000 --- a/.gitlab-ci.yml +++ /dev/null @@ -1,30 +0,0 @@ -image: maven:3.3.9-jdk-8 - -cache: - paths: - - .m2/repository - -stages: - - test - - deploy - - -test: - stage: test - script: - - cp "$APP_TEST" ./src/main/resources/application-test.properties - - mvn clean test && cat target/site/jacoco/index.html - -deploy: - stage: deploy - script: - - cp "$APP_PROD" ./src/main/resources/application-prod.properties - - mvn package -DskipTests - - eval $(ssh-agent -s) - - ssh-add <(echo "$SSH_PRIVATE_KEY" | base64 --decode) - - mkdir -p ~/.ssh - - chmod 700 ~/.ssh - - ssh-keyscan celess.cn >> ~/.ssh/known_hosts - - chmod 644 ~/.ssh/known_hosts - - scp target/blog-0.0.1-SNAPSHOT.jar root@celess.cn:/www/wwwroot/api.celess.cn - - ssh root@celess.cn "cd /www/wwwroot/api.celess.cn && bash build.sh" \ No newline at end of file