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

ci: Deploy pages #703

Merged
merged 104 commits into from
Sep 3, 2024
Merged
Changes from 101 commits
Commits
Show all changes
104 commits
Select commit Hold shift + click to select a range
e7c985c
test mounting cargo cache
ggera Aug 19, 2024
f6ab246
fix permission
ggera Aug 19, 2024
5c4c31d
build images in gh
ggera Aug 19, 2024
b0db060
fix ecr login
ggera Aug 19, 2024
ed07cbc
macos runner
ggera Aug 20, 2024
5e9fc82
run sequentially to release resouces
ggera Aug 20, 2024
afec45a
build release outside docker
ggera Aug 20, 2024
bf168cf
undo Dockerfile changes
ggera Aug 20, 2024
550480d
minor
ggera Aug 20, 2024
d358837
trigger gitlab pipleine from gh action
ggera Aug 20, 2024
569c503
fix: formatting
ggera Aug 20, 2024
836ca94
formatting
ggera Aug 20, 2024
790004f
get commit message in a step
ggera Aug 21, 2024
d076768
fix clippy
ggera Aug 21, 2024
2eaefaf
remove target from cache
ggera Aug 21, 2024
35cc01d
Use single workflow
ntn-x2 Aug 22, 2024
0424e3d
Add delimiters
ntn-x2 Aug 22, 2024
e6831ca
Update nightly version and add job dependencies
ntn-x2 Aug 22, 2024
fc72254
Add job dependencies
ntn-x2 Aug 22, 2024
6ff0db0
Trigger Gitlab pipeline only via web hooks
ntn-x2 Aug 22, 2024
f1a7af1
Fix gitlab pipeline syntax
ntn-x2 Aug 22, 2024
898685c
Integration tests must depend on Clippy
ntn-x2 Aug 22, 2024
0a35940
Add space cleaning
ntn-x2 Aug 22, 2024
ceb28ee
append cargo hash to cache key
ggera Aug 22, 2024
8c428fd
Do not fail whole matrix
ntn-x2 Aug 23, 2024
b6d83e0
Fix commit head job
ntn-x2 Aug 23, 2024
7e285f0
Different way for commit message
ntn-x2 Aug 23, 2024
c4cd422
ci-skip-rust
ggera Aug 23, 2024
3ea3c3f
ci-skip-rust
ggera Aug 23, 2024
915ad77
use deploy page
ggera Aug 27, 2024
c536021
resolve 404
ggera Aug 27, 2024
03f180e
fix permissions
ggera Aug 28, 2024
c3e2ab0
ci-skip-rust
ggera Aug 28, 2024
b375bc5
fix docs publishing
ggera Aug 28, 2024
28da2d1
merege gh-runner
ggera Aug 28, 2024
ecb3ce2
ci-skip-rust
ggera Aug 28, 2024
1af43f0
test mounting cargo cache
ggera Aug 19, 2024
0b98788
fix permission
ggera Aug 19, 2024
ad2819b
build images in gh
ggera Aug 19, 2024
0b90a1e
fix ecr login
ggera Aug 19, 2024
d535977
macos runner
ggera Aug 20, 2024
cd186f8
run sequentially to release resouces
ggera Aug 20, 2024
344fbc2
build release outside docker
ggera Aug 20, 2024
5dfd569
undo Dockerfile changes
ggera Aug 20, 2024
8e26411
minor
ggera Aug 20, 2024
1986c5d
trigger gitlab pipleine from gh action
ggera Aug 20, 2024
a31fa3c
fix: formatting
ggera Aug 20, 2024
3116e96
formatting
ggera Aug 20, 2024
30bd9c9
get commit message in a step
ggera Aug 21, 2024
c5f38b2
fix clippy
ggera Aug 21, 2024
e4abc79
remove target from cache
ggera Aug 21, 2024
1a0e05d
Use single workflow
ntn-x2 Aug 22, 2024
3156339
Add delimiters
ntn-x2 Aug 22, 2024
1b83179
Update nightly version and add job dependencies
ntn-x2 Aug 22, 2024
b442ab0
Add job dependencies
ntn-x2 Aug 22, 2024
4d4ff5f
Trigger Gitlab pipeline only via web hooks
ntn-x2 Aug 22, 2024
4ddd5c4
Fix gitlab pipeline syntax
ntn-x2 Aug 22, 2024
642085b
Integration tests must depend on Clippy
ntn-x2 Aug 22, 2024
b4399aa
Add space cleaning
ntn-x2 Aug 22, 2024
64b21de
append cargo hash to cache key
ggera Aug 22, 2024
ee71460
Do not fail whole matrix
ntn-x2 Aug 23, 2024
a017d3b
Fix commit head job
ntn-x2 Aug 23, 2024
d6c2342
Different way for commit message
ntn-x2 Aug 23, 2024
ddc7271
ci-skip-rust
ggera Aug 23, 2024
fc08aea
ci-skip-rust
ggera Aug 23, 2024
3295fb0
Last changes
ntn-x2 Aug 29, 2024
875552d
rebase
ggera Aug 29, 2024
3793378
merge
ggera Aug 29, 2024
34c5f4a
publish master branch as default
ggera Aug 29, 2024
f0b4633
Use right version of nightly for rustfmt job
ntn-x2 Aug 29, 2024
2adbe60
Add cargo cache for two more jobs
ntn-x2 Aug 29, 2024
2f01b0f
Remove isolation for vitest files
ntn-x2 Aug 29, 2024
68cd6de
ci-skip-rust
ntn-x2 Aug 29, 2024
436302b
minor
ggera Aug 29, 2024
9a3154a
Install fmt nightly toolchain
ntn-x2 Aug 29, 2024
48da3a1
ci-skip-rust
ntn-x2 Aug 29, 2024
920435b
test commit message
ntn-x2 Aug 29, 2024
b064963
test commit message
ntn-x2 Aug 29, 2024
d6d5820
test commit message 3
ntn-x2 Aug 29, 2024
fc0a881
test commit message 4
ntn-x2 Aug 29, 2024
5f4bd84
test commit message 5
ntn-x2 Aug 29, 2024
c6b572c
test commit message 6
ntn-x2 Aug 29, 2024
9eab874
ci-skip-rust
ntn-x2 Aug 29, 2024
5392b54
Add always() for job dependency
ntn-x2 Aug 29, 2024
543163e
ci-skip-rust
ntn-x2 Aug 29, 2024
55f0437
Revert file parallelism flag
ntn-x2 Aug 29, 2024
0017031
ci-skip-rust
ntn-x2 Aug 29, 2024
6426f07
ci-skip-rust
ntn-x2 Aug 29, 2024
b765a35
Revert parallelism
ntn-x2 Aug 29, 2024
c5ddd59
ci-skip-rust
ntn-x2 Aug 29, 2024
9ad71ad
Merge branch 'github-runner' of github.com:KILTprotocol/mashnet-node …
ggera Aug 29, 2024
b1bc8ef
merging
ggera Aug 29, 2024
5827146
merging
ggera Aug 29, 2024
f3f0588
merge
ggera Aug 30, 2024
29573d3
Merge branch 'develop' into deploy-pages
ggera Aug 30, 2024
e374943
Merge branch 'develop' of github.com:KILTprotocol/mashnet-node into d…
ggera Sep 2, 2024
b4e07ec
minor
ggera Sep 2, 2024
b3a3a8f
Merge branch 'deploy-pages' of github.com:KILTprotocol/mashnet-node i…
ggera Sep 2, 2024
d4de94d
fix typo
ggera Sep 2, 2024
b64f2c0
fix reference
ggera Sep 2, 2024
21e2894
Merge branch 'develop' into deploy-pages
ggera Sep 2, 2024
47286b6
formatting
ggera Sep 3, 2024
dfaeaff
Merge branch 'deploy-pages' of github.com:KILTprotocol/mashnet-node i…
ggera Sep 3, 2024
87a0bf7
Merge branch 'develop' into deploy-pages
ggera Sep 3, 2024
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
60 changes: 54 additions & 6 deletions .github/workflows/publish-rustdocs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,19 +11,30 @@ on:
types:
- completed

permissions:
contents: write
pages: write
id-token: write

concurrency:
group: ${{ github.workflow }}-${{ github.ref_name }}
cancel-in-progress: true

jobs:
deploy-rustdocs:
name: Deploy rustdoc
build-rustdoc:
name: Build rustdoc
runs-on: ubuntu-latest
env:
DOCS_TARGET: target/doc
BRANCH: gh-pages
if: ${{ github.event_name == 'workflow_dispatch' || (github.event_name == 'workflow_run' && github.event.workflow_run.conclusion == 'success') }}

steps:
- name: Free Disk Space
uses: jlumbroso/free-disk-space@main
with:
tool-cache: true

- name: Checkout repository
uses: actions/checkout@v4

Expand All @@ -42,13 +53,50 @@ jobs:
docker run --rm \
-v "${GITHUB_WORKSPACE}:/workspace" \
-v "${HOME}/.cargo:/root/.cargo" \
-w /workspace \
-e RUSTDOCFLAGS='-D warnings' \
ntn-x2 marked this conversation as resolved.
Show resolved Hide resolved
-w /workspace \
paritytech/ci-unified:bullseye-1.74.0 \
bash -c "cargo doc --all-features --no-deps --locked && chown -R $(id -u):$(id -g) ${{ env.DOCS_TARGET }}"
bash -c "
cargo doc --all-features --no-deps --locked && \
mv $DOCS_TARGET/help.html $DOCS_TARGET/index.html && chown -R $(id -u):$(id -g) $DOCS_TARGET"
ntn-x2 marked this conversation as resolved.
Show resolved Hide resolved
ntn-x2 marked this conversation as resolved.
Show resolved Hide resolved

- name: Deploy to GitHub Pages
- name: Set target folder for non-master branches
if: github.ref_name != 'master'
run: echo "TARGET_FOLDER=${{ github.ref_name }}" >> $GITHUB_ENV

- name: Push to gh-pages branch
uses: JamesIves/github-pages-deploy-action@v4
with:
branch: gh-pages-${{ github.ref_name }}
branch: ${{ env.BRANCH }}
folder: ${{ env.DOCS_TARGET }}
target-folder: ${{ env.TARGET_FOLDER }}
ntn-x2 marked this conversation as resolved.
Show resolved Hide resolved


deploy-rustdoc:
name: Deploy rustdoc
environment:
name: gh-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
needs: build-rustdoc
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: gh-pages

- name: Setup Pages
uses: actions/configure-pages@v5

- name: Build with Jekyll
uses: actions/jekyll-build-pages@v1
with:
source: ./
destination: ./_site

- name: Upload artifact
uses: actions/upload-pages-artifact@v3

- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4
Loading