nealrichardson commented on a change in pull request #16: ARROW-6260: [Website] 
Use deploy key on Travis to build and push to asf-site
URL: https://github.com/apache/arrow-site/pull/16#discussion_r316486127
 
 

 ##########
 File path: build-and-deploy.sh
 ##########
 @@ -35,7 +35,18 @@ if [ "${TRAVIS_BRANCH}" = "master" ] && [ 
"${TRAVIS_PULL_REQUEST}" = "false" ];
     JEKYLL_ENV=production bundle exec jekyll build --baseurl="${BASE_URL}"
 
     # Publish
-    git clone -b ${TARGET_BRANCH} 
https://${GITHUB_PAT}@github.com/$TRAVIS_REPO_SLUG.git OUTPUT
+    if [ "${DEPLOY_KEY}" != "" ]; then
+        echo "Setting deploy key"
+        eval $(ssh-agent -s)
+        # Hack to make the key from the env var have real newlines
+        echo "${DEPLOY_KEY}" | sed -e 's/\\n/\
+/g' | ssh-add -
 
 Review comment:
   Didn't work on my mac but it doesn't have to as long as it works on Travis ;)
   
   I'll give it a shot. 

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


With regards,
Apache Git Services

Reply via email to