The public sources for my resume. These sources are auto compiled and published upon changes.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

71 lines
1.8 KiB

  1. stages:
  2. - build
  3. - deploy
  4. build-resume:
  5. stage: build
  6. script:
  7. - ./scripts/build-pdf-resume.sh
  8. - ./scripts/build-pdf-resume-for-recruiters.sh
  9. - ./scripts/build-html-resume.sh
  10. only:
  11. - master
  12. tags:
  13. - linux
  14. artifacts:
  15. paths:
  16. - resume.pdf
  17. - resume_for_recruiters.pdf
  18. - ResumeSite.tar.gz
  19. deploy-resume-site:
  20. image: sothr.com/deploy:ubuntu
  21. stage: deploy
  22. variables:
  23. TARGET_DIRECTORY: "/srv/www/sothr.com/resume"
  24. script:
  25. - eval `ssh-agent -s`
  26. - ssh-add <(echo "$SSH_DEPLOY_KEY")
  27. - mkdir -p ~/.ssh
  28. - ssh-keyscan -p $DEPLOY_PORT sothr.com >> ~/.ssh/known_hosts
  29. - mkdir /tmp/deploy
  30. - tar -xvf ResumeSite.tar.gz -C /tmp/deploy
  31. - cp resume.pdf /tmp/deploy
  32. - cp resume_for_recruiters.pdf /tmp/deploy
  33. - rsync -avz --delete-delay -e "ssh -o StrictHostKeyChecking=no -o UserKnownHostsFile=/dev/null -p $DEPLOY_PORT" --progress /tmp/deploy/* $DEPLOY_USER@$DEPLOY_HOST:$TARGET_DIRECTORY
  34. only:
  35. - master
  36. tags:
  37. - docker
  38. environment: production
  39. deploy-resume-github:
  40. image: sothr.com/deploy:ubuntu
  41. stage: deploy
  42. variables:
  43. GIT_REPO: git@github.com:warricksothr/resume.git
  44. script:
  45. - eval `ssh-agent -s`
  46. - ssh-add <(echo "$SSH_DEPLOY_KEY")
  47. - mkdir -p ~/.ssh
  48. - ssh-keyscan github.com >> ~/.ssh/known_hosts
  49. - git clone $GIT_REPO /tmp/deploy
  50. - pushd /tmp/deploy
  51. - git checkout -b gh-pages origin/gh-pages
  52. - git config --global user.email "warrick@sothr.com"
  53. - git config --global user.name "Drew Short"
  54. - rm -rf *
  55. - popd
  56. - tar -xvf ResumeSite.tar.gz -C /tmp/deploy
  57. - cp resume.pdf /tmp/deploy
  58. - cp resume_for_recruiters.pdf /tmp/deploy
  59. - pushd /tmp/deploy
  60. - git add .
  61. - git commit -am"$CI_COMMIT_MESSAGE"
  62. - git push
  63. - popd
  64. only:
  65. - master
  66. tags:
  67. - docker
  68. environment: production