forked from sundowndev/phoneinfoga
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: init CD job to deploy docs (sundowndev#165)
- Loading branch information
1 parent
5865243
commit c96bed2
Showing
1 changed file
with
34 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,34 @@ | ||
name: Documentation CI | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
|
||
jobs: | ||
publish: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [12.x] | ||
steps: | ||
- uses: actions/checkout@v1 | ||
- name: Set up Python 3.8 | ||
uses: actions/setup-python@v1 | ||
with: | ||
python-version: 3.8 | ||
- name: Install dependencies | ||
run: | | ||
python -m pip install --upgrade pip | ||
pip install mkdocs mkdocs-material | ||
- name: Deploy | ||
run: | | ||
SSH_DIR="${HOME}/.ssh" | ||
mkdir "${SSH_DIR}" | ||
ssh-keyscan -t rsa github.com > "${SSH_DIR}/known_hosts" | ||
echo "${{ secrets.ACTIONS_DEPLOY_KEY }}" > "${SSH_DIR}/id_rsa" | ||
chmod 400 "${SSH_DIR}/id_rsa" | ||
git remote set-url origin [email protected]:sundowndev/PhoneInfoga.git | ||
git config user.name "${{ secrets.GITHUB_USER }}" | ||
git config user.email "${{ secrets.GITHUB_USER }}@users.noreply.github.com" | ||
mkdocs gh-deploy |