File tree Expand file tree Collapse file tree 4 files changed +29
-40
lines changed Expand file tree Collapse file tree 4 files changed +29
-40
lines changed Original file line number Diff line number Diff line change
1
+ name : deploy
2
+ on :
3
+ push :
4
+ branches :
5
+ - master
6
+ jobs :
7
+ deploy :
8
+ runs-on : ubuntu-20.04
9
+ steps :
10
+ - uses : actions/checkout@v2
11
+ - uses : actions/setup-python@v2
12
+ with :
13
+ python-version : 3.8
14
+ - uses : actions/setup-node@v1
15
+ with :
16
+ node-version : 14
17
+ - run : pip install commonmark==0.9.1
18
+ - run : npm install
19
+ - run : shellcheck deploy.sh
20
+ - run : shellcheck resources.whatwg.org/build/*.sh
21
+ - run : bash ./deploy.sh
22
+ env :
23
+ SERVER : ${{ secrets.MARQUEE_SERVER }}
24
+ SERVER_PUBLIC_KEY : ${{ secrets.MARQUEE_PUBLIC_KEY }}
25
+ SERVER_DEPLOY_KEY : ${{ secrets.MARQUEE_DEPLOY_KEY }}
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -62,23 +62,12 @@ if [[ "$TRAVIS" == "true" ]]; then
62
62
fi
63
63
64
64
# This ensures that only changes to the master branch get deployed
65
- if [[ " $TRAVIS_BRANCH " != " master" || " $TRAVIS_PULL_REQUEST " != " false " ]]; then
65
+ if [[ " $GITHUB_REF " != " refs/heads/ master" ]]; then
66
66
header " Skipping deploy"
67
67
else
68
68
header " Synchronizing content with whatwg.org et al"
69
- ENCRYPTED_KEY_VAR=" encrypted_${ENCRYPTION_LABEL} _key"
70
- ENCRYPTED_IV_VAR=" encrypted_${ENCRYPTION_LABEL} _iv"
71
- ENCRYPTED_KEY=${! ENCRYPTED_KEY_VAR}
72
- ENCRYPTED_IV=${! ENCRYPTED_IV_VAR}
73
- openssl aes-256-cbc -K " $ENCRYPTED_KEY " -iv " $ENCRYPTED_IV " -in deploy_key.enc -out deploy_key -d
74
- chmod 600 deploy_key
75
69
eval " $( ssh-agent -s) "
76
- ssh-add deploy_key
77
- echo " $SERVER $SERVER_PUBLIC_KEY " > known_hosts
78
- # --verbose isn't used because there are too many files to list them all
79
- # without exceeding log size limits:
80
- # https://github.com/whatwg/whatwg.org/issues/287
81
- rsync --archive --chmod=" D755,F644" --compress --delete --stats --log-file=" rsync-log.txt" --rsh=" ssh -o UserKnownHostsFile=known_hosts" ./whatwg.org ./* .whatwg.org " deploy@$SERVER :/var/www/"
82
- scp -o=" UserKnownHostsFile=known_hosts" rsync-log.txt " deploy@$SERVER :/var/www/whatwg.org/"
83
- echo " Full rsync log at https://whatwg.org/rsync-log.txt"
70
+ echo " $SERVER_DEPLOY_KEY " | ssh-add -
71
+ mkdir -p ~ /.ssh/ && echo " $SERVER $SERVER_PUBLIC_KEY " > ~ /.ssh/known_hosts
72
+ rsync --archive --chmod=" D755,F644" --compress --delete --verbose ./whatwg.org ./* .whatwg.org " deploy@$SERVER :/var/www/"
84
73
fi
You can’t perform that action at this time.
0 commit comments