Skip to content

Instantly share code, notes, and snippets.

@seogi1004
Created January 30, 2019 15:03
Show Gist options
  • Save seogi1004/f1a2732babf0ef8a28366d9cb3305377 to your computer and use it in GitHub Desktop.
Save seogi1004/f1a2732babf0ef8a28366d9cb3305377 to your computer and use it in GitHub Desktop.
Deploy:
image: maven:3.3.9
stage: deploy
before_script:
- apt-get update -qq && apt-get install -y -qq sshpass
script:
- POM_VERSION=$(mvn -q -Dexec.executable=echo -Dexec.args='${project.version}' --non-recursive exec:exec)
after_script:
- ls -all ./dist
- sshpass -V
- export SSHPASS=$SSH_PASSWORD
# SSH 포트가 22가 아니라면 -P 옵션을 줄것
- sshpass -e scp -r -oStrictHostKeyChecking=no ./dist/vuejs-springboot-starter-$POM_VERSION.jar root@180.228.199.230:/opt/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment