-
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy path.travis.yml
60 lines (48 loc) · 1.57 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
language: ruby
sudo: false
cache:
apt: true
bundler: true
directories:
- "$TRAVIS_BUILD_DIR/tmp/.htmlproofer"
notifications:
email:
on_success: never
branches:
only: master
env:
global:
- JEKYLL_ENV="production"
- NOKOGIRI_USE_SYSTEM_LIBRARIES=true
addons:
apt:
packages:
- libcurl4-openssl-dev # resolve SSL issue of htmlproofer
- locales-all
- libgsl-dev # gsl gem
- rsync
rvm:
- 2.7
script:
- bundle exec jekyll build --trace
# https://github.com/gjtorikian/html-proofer/wiki/Using-HTMLProofer-From-Ruby-and-Travis
- bundle exec htmlproofer ./_site --check-external-hash --check-opengraph --check-sri --check-html --http-status-ignore 999 --check-img-http --timeframe 4w || true
after_success:
- find ./_site -type f
before_deploy:
- ssh-keyscan -t rsa -p "$DEPLOY_SSH_PORT" -H "$DEPLOY_SSH_HOST" 2>&1 | tee -a ${TRAVIS_HOME}/.ssh/known_hosts
- openssl aes-256-cbc -K $encrypted_bc790a28b861_key -iv $encrypted_bc790a28b861_iv -in tools/deploy_rsa.enc -out "$DEPLOY_SSH_KEY" -d
- eval "$(ssh-agent -s)"
- chmod 600 "$DEPLOY_SSH_KEY"
- ssh-add "$DEPLOY_SSH_KEY"
deploy:
provider: script
skip_cleanup: true
script:
#- ssh -vvv -i "$DEPLOY_SSH_KEY" -p "$DEPLOY_SSH_PORT" "$DEPLOY_SSH_USER"@"$DEPLOY_SSH_HOST"
#- rsync --version
- rsync -avzcP --exclude=tools/ --exclude=README.md --delete-after --delete-excluded -e "ssh -o StrictHostKeyChecking=no -i $DEPLOY_SSH_KEY -p $DEPLOY_SSH_PORT" "$TRAVIS_BUILD_DIR/_site" "$DEPLOY_SSH_USER"@"$DEPLOY_SSH_HOST":"$DEPLOY_SSH_PATH"/
on:
branch: master
rvm: 2.7
# vim: set ts=2 sw=2 ai si et: