So I am using Wercker to auto-deploy my Hugo blog to Github Pages. The Build step in Wercker is working fine, but toward the end of the Deploy step I get the error "gh-pages failed pushing to github pages"
I am specifically using the lukevivier/gh-pages step for deployment. My YAML is as follows:
box: debian
build:
steps:
- arjen/hugo-build:
version: "0.14"
theme: hugo-agency-theme
flags: --buildDrafts=true
deploy:
steps:
- install-packages:
packages: git ssh-client
- lukevivier/gh-pages:
token: $GIT_TOKEN
basedir: public
domain: johnnyjanzen.github.io
The error log is as follows
export WERCKER_STEP_ROOT="/pipeline/gh-pages-37f7864e-6ccb-403c-88bd-004af3de71ac"
export WERCKER_STEP_ID="gh-pages-37f7864e-6ccb-403c-88bd-004af3de71ac"
export WERCKER_STEP_OWNER="lukevivier"
export WERCKER_STEP_NAME="gh-pages"
export WERCKER_REPORT_NUMBERS_FILE="/report/gh-pages-37f7864e-6ccb-403c-88bd-004af3de71ac/numbers.ini"
export WERCKER_REPORT_MESSAGE_FILE="/report/gh-pages-37f7864e-6ccb-403c-88bd-004af3de71ac/message.txt"
export WERCKER_REPORT_ARTIFACTS_DIR="/report/gh-pages-37f7864e-6ccb-403c-88bd-004af3de71ac/artifacts"
export WERCKER_GH_PAGES_TOKEN="$GIT_TOKEN"
export WERCKER_GH_PAGES_BASEDIR="public"
export WERCKER_GH_PAGES_DOMAIN="johnnyjanzen.github.io"
source "/pipeline/gh-pages-37f7864e-6ccb-403c-88bd-004af3de71ac/run.sh" < /dev/null
using github repo "johnnyjanzen/mmucan"
Initialized empty Git repository in /pipeline/source/public/.git/
[master (root-commit) bcacf48] deploy from johnnyjanzen
104 files changed, 19649 insertions(+)
create mode 100644 .DS_Store
create mode 100644 404.html
create mode 100644 CNAME
create mode 100644 css/agency.css
create mode 100644 css/bootstrap.css
create mode 100644 css/bootstrap.min.css
create mode 100755 css/dependenciesBAD.css
create mode 100755 css/styleddBAD.css
create mode 100644 font-awesome/css/font-awesome.css
create mode 100644 font-awesome/css/font-awesome.min.css
create mode 100644 font-awesome/fonts/FontAwesome.otf
create mode 100644 font-awesome/fonts/fontawesome-webfont.eot
create mode 100644 font-awesome/fonts/fontawesome-webfont.svg
create mode 100644 font-awesome/fonts/fontawesome-webfont.ttf
create mode 100644 font-awesome/fonts/fontawesome-webfont.woff
create mode 100644 font-awesome/less/bordered-pulled.less
create mode 100644 font-awesome/less/core.less
create mode 100644 font-awesome/less/fixed-width.less
create mode 100644 font-awesome/less/font-awesome.less
create mode 100644 font-awesome/less/icons.less
create mode 100644 font-awesome/less/larger.less
create mode 100644 font-awesome/less/list.less
create mode 100644 font-awesome/less/mixins.less
create mode 100644 font-awesome/less/path.less
create mode 100644 font-awesome/less/rotated-flipped.less
create mode 100644 font-awesome/less/spinning.less
create mode 100644 font-awesome/less/stacked.less
create mode 100644 font-awesome/less/variables.less
create mode 100644 font-awesome/scss/_bordered-pulled.scss
create mode 100644 font-awesome/scss/_core.scss
create mode 100644 font-awesome/scss/_fixed-width.scss
create mode 100644 font-awesome/scss/_icons.scss
create mode 100644 font-awesome/scss/_larger.scss
create mode 100644 font-awesome/scss/_list.scss
create mode 100644 font-awesome/scss/_mixins.scss
create mode 100644 font-awesome/scss/_path.scss
create mode 100644 font-awesome/scss/_rotated-flipped.scss
create mode 100644 font-awesome/scss/_spinning.scss
create mode 100644 font-awesome/scss/_stacked.scss
create mode 100644 font-awesome/scss/_variables.scss
create mode 100644 font-awesome/scss/font-awesome.scss
create mode 100644 fonts/glyphicons-halflings-regular.eot
create mode 100644 fonts/glyphicons-halflings-regular.svg
create mode 100644 fonts/glyphicons-halflings-regular.ttf
create mode 100644 fonts/glyphicons-halflings-regular.woff
create mode 100644 fonts/glyphicons-halflings-regular.woff2
create mode 100644 img/about/1.jpg
create mode 100644 img/about/2.jpg
create mode 100644 img/about/3.jpg
create mode 100644 img/about/4.jpg
create mode 100644 img/header-bg.jpg
create mode 100644 img/logo_1_transparent.png
create mode 100644 img/logos/aetuts.jpg
create mode 100644 img/logos/creative-market.jpg
create mode 100644 img/logos/designmodo.jpg
create mode 100644 img/logos/envato.jpg
create mode 100644 img/logos/microlancer.jpg
create mode 100644 img/logos/themeforest.jpg
create mode 100644 img/logos/wordpress.jpg
create mode 100644 img/map-image.png
create mode 100644 img/portfolio/dreams-preview.png
create mode 100644 img/portfolio/dreams.png
create mode 100644 img/portfolio/escape-preview.png
create mode 100644 img/portfolio/escape.png
create mode 100644 img/portfolio/golden-preview.png
create mode 100644 img/portfolio/golden.png
create mode 100644 img/portfolio/roundicons-preview.png
create mode 100644 img/portfolio/roundicons.png
create mode 100644 img/portfolio/startup-framework-preview.png
create mode 100644 img/portfolio/startup-framework.png
create mode 100644 img/portfolio/treehouse-preview.png
create mode 100644 img/portfolio/treehouse.png
create mode 100644 img/team/1.jpg
create mode 100644 img/team/2.jpg
create mode 100644 img/team/3.jpg
create mode 100644 index.html
create mode 100644 index.xml
create mode 100644 js/agency.js
create mode 100644 js/bootstrap.js
create mode 100644 js/bootstrap.min.js
create mode 100644 js/cbpAnimatedHeader.js
create mode 100644 js/cbpAnimatedHeader.min.js
create mode 100644 js/classie.js
create mode 100644 js/contact_me.js
create mode 100755 js/dependencies.js
create mode 100644 js/jqBootstrapValidation.js
create mode 100644 js/jquery.js
create mode 100755 js/script.js
create mode 100644 page/1/index.html
create mode 100644 page/2/index.html
create mode 100644 post/2016-02-11-your-filename/index.html
create mode 100644 post/index.html
create mode 100644 post/index.xml
create mode 100644 post/mynew copy 2/index.html
create mode 100644 post/mynew copy 3/index.html
create mode 100644 post/mynew copy 4/index.html
create mode 100644 post/mynew copy 5/index.html
create mode 100644 post/mynew copy 6/index.html
create mode 100644 post/mynew copy 7/index.html
create mode 100644 post/mynew copy/index.html
create mode 100644 post/mynew/index.html
create mode 100644 post/mynew2/index.html
create mode 100644 post/page/1/index.html
create mode 100644 sitemap.xml
remote: Permission to johnnyjanzen/mmucan.git denied to johnnyjanzen.
fatal: unable to access 'https://**my github personal access token**@github.com/johnnyjanzen/mmucan.git/': The requested URL returned error: 403
/pipeline/gh-pages-37f7864e-6ccb-403c-88bd-004af3de71ac/run.sh: line 60: warning: command not found
failed: failed pushing to github pages
I have created a personal access token in my github account, and placed it in Wercker as an environment variable.
The first time I tried this, my main /mmucan git repository only contained one branch (master). I read online somewhere that Wercker depends on there being a gh-pages branch, so I created this branch (which is identical to the master branch) but the exact same error log was returned.
Any help would be very appreciated, cheers!
I answered my own question. I read the "personal access token" wrong on Github, and thought you ticked the boxes to LIMIT (aka, disable) access for the token. So i left all the boxes unticked haha.
The correct thing to do is to tick all the boxes referring to repository access when you make the personal access token.