-
Notifications
You must be signed in to change notification settings - Fork 19
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore(build): add ssh key setup to docdeploy
- Loading branch information
Showing
1 changed file
with
8 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,13 +4,19 @@ set -e | |
|
||
if [ "$TRAVIS_REPO_SLUG" == "fgpv-vpgf/geoApi" ] && [ -n "$TRAVIS_TAG" ]; then | ||
npm run doc | ||
# this section assumes the id_rsa key has already been decrypted | ||
# devdeploy.sh should run before this script | ||
|
||
openssl aes-256-cbc -k "$PW" -out ~/.ssh/id_rsa -in devkey.enc -d | ||
echo -e "Host *\n\tStrictHostKeyChecking no\n" >> ~/.ssh/config | ||
chmod 600 ~/.ssh/id_rsa | ||
eval `ssh-agent -s` | ||
ssh-add ~/.ssh/id_rsa | ||
|
||
git clone --depth=1 [email protected]:fgpv-vpgf/geoApi.git -b gh-pages ghdocs | ||
ls ghdocs | ||
mkdir -p ghdocs/$TRAVIS_TAG | ||
rsync -av --delete docbuild/ ghdocs/$TRAVIS_TAG/ | ||
bash ./scripts/make_doc_index.sh ghdocs/ > ghdocs/index.html | ||
|
||
cd ghdocs | ||
git add $TRAVIS_TAG | ||
git add index.html | ||
|