Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deploy test #196

Closed
wants to merge 1 commit into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
62 changes: 62 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
# vim:sw=2:ts=2
# build html version of docs
name: build

# on events
on:
pull_request:
branches:
- master
- 'feature/*'

jobs:
build:
runs-on: ubuntu-latest
name: build

steps:
- uses: actions/checkout@v4
- uses: sphinx-doc/github-problem-matcher@master

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: "3.10"

- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r requirements.txt

- name: Build docs
run: |
make clean html

- name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: html_build
path: _build
if-no-files-found: error

deploy:
runs-on: ubuntu-latest
name: deploy-on-merge
needs: build

steps:
- name: Download build artifact
uses: actions/download-artifact@v4
with:
name: html_build
path: _build
if-no-files-found: error

- name: Install lftp
run: |
sudo apt install -y lftp

- name: Deploy docs
run: |
ls -la
lftp -v -c "open -u lftp:1234 81.15.242.168:11022; ls"
49 changes: 49 additions & 0 deletions .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
# vim:sw=2:ts=2
# build html version of docs and deploy to docs.phoenix-rtos.com
name: deploy

# on events
on:
push:
branches:
- master
- 'feature/*'

jobs:
build:
runs-on: ubuntu-latest
name: build

steps:
name: Build docs
uses: phoenix-rtos/phoenix-rtos-project/phoenix-rtos-doc/.github/workflows/build.yml@master

name: Upload artifact
uses: actions/upload-artifact@v4
with:
name: html_build
path: _build
if-no-files-found: error

deploy:
runs-on: ubuntu-latest
name: deploy-on-merge
needs: build

steps:
- name: Download build artifact
uses: actions/download-artifact@v4
with:
name: html_build
path: _build
if-no-files-found: error

- name: Deploy docs
run: |
touch key
echo "" > key
sftp -i key -P 11022 sftpuser@81.15.242.168 <<EOF
cd uploads
put -R _build
bye
EOF
5 changes: 5 additions & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
sphinx==7.2.6
sphinx_copybutton==0.5.2
myst-parser==2.0.0
furo==2024.1.29
pygments==2.17.2
Loading