From 93ee1265c2bd214779a97e20152d22a34f0b8281 Mon Sep 17 00:00:00 2001 From: Simon Prochazka Date: Wed, 18 Nov 2020 21:06:19 +0000 Subject: [PATCH] docs: add documentation deploy job --- .github/workflows/documentation.yml | 41 +++++++++++++++++++++++++++++ 1 file changed, 41 insertions(+) create mode 100644 .github/workflows/documentation.yml diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml new file mode 100644 index 00000000..70ae102f --- /dev/null +++ b/.github/workflows/documentation.yml @@ -0,0 +1,41 @@ +name: documentation + +on: + push: + branches: + - "master" + paths: + - "docs/**" + +jobs: + documentation: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - uses: actions/setup-node@v1 + with: + node-version: "12.x" + - name: Add key to allow access to repository + env: + SSH_AUTH_SOCK: /tmp/ssh_agent.sock + run: | + mkdir -p ~/.ssh + ssh-keyscan github.com >> ~/.ssh/known_hosts + echo "${{ secrets.GH_PAGES_DEPLOY }}" > ~/.ssh/id_rsa + chmod 600 ~/.ssh/id_rsa + cat <> ~/.ssh/config + Host github.com + HostName github.com + IdentityFile ~/.ssh/id_rsa + EOT + - name: Release to GitHub Pages + env: + USE_SSH: true + GIT_USER: git + ALGOLIA_KEY: ${{ secrets.ALGOLIA_KEY }} + run: | + git config --global user.email "bot@aevea.io" + git config --global user.name "aevea-bot" + cd www + yarn + yarn deploy