forgejo-deb/.forgejo/workflows/forgejo-deb.yml

125 lines
3.2 KiB
YAML
Raw Normal View History

2024-06-15 13:02:06 +10:00
on:
push:
tags:
- "*"
2024-04-28 10:55:53 +10:00
jobs:
build-forgejo-deb:
2024-06-15 12:20:47 +10:00
runs-on: bookworm
2024-04-28 10:55:53 +10:00
steps:
- uses: actions/checkout@v4
with:
submodules: true
fetch-depth: 0
fetch-tags: true
filter: tree:0
2024-04-28 10:55:53 +10:00
2024-06-15 13:21:32 +10:00
- uses: actions/setup-node@v3
with:
node-version: 20
2024-04-28 10:55:53 +10:00
- uses: actions/setup-go@v4
with:
go-version: "1.22"
check-latest: true
- name: "actions prep: build-forgejo-deb"
id: ciprep
run: ./.ci-make.sh actions-prep build-forgejo-deb
- uses: crystal/install-jq-action@v2.1.0
- run: ./.ci-make.sh ci-verify forgejo
- run: ./.ci-make.sh submodule-make forgejo deps-frontend
- run: ./.ci-make.sh submodule-make forgejo deps-backend
- name: tag pre-condition
run: |
cd forgejo
git update-ref refs/heads/tag_test $(git rev-parse --verify HEAD)
2024-06-15 12:33:59 +10:00
# - run: ./.ci-make.sh submodule-make forgejo security-check
2024-06-15 12:00:52 +10:00
2024-04-28 10:55:53 +10:00
- run: ./.ci-make.sh submodule-make forgejo frontend
2024-06-15 12:33:59 +10:00
# - run: ./.ci-make.sh submodule-make forgejo checks-backend
2024-04-28 10:55:53 +10:00
- name: Download Forgejo binary
run: ./.ci-make.sh download-binary forgejo-bin-dl
2024-06-15 11:52:44 +10:00
- name: Build Forgejo for arm64
2024-04-28 10:55:53 +10:00
run: ./.ci-make.sh submodule-build forgejo forgejo-bin
env:
TAGS: bindata
- run: ./.ci-make.sh package-prep
- run: ./.ci-make.sh package-build-deps
- run: ./.ci-make.sh package-build actions
- run: ./.ci-make.sh package-clean
- name: generate sha256
run: |
./.ci-make.sh pkg-gen-sha256
./.ci-make.sh preview-sha256
- uses: actions/upload-artifact@v3
with:
name: forgejo-deb-${{ steps.ciprep.outputs.artifactlabel }}
path: |
*.deb
*.deb.sha256
installtest-bookworm-user:
2024-06-15 12:20:47 +10:00
runs-on: bookworm
2024-04-28 10:55:53 +10:00
steps:
- uses: actions/checkout@v4
- name: "actions prep: installtest"
id: ciprep
run: ./.ci-make.sh actions-prep installtest
- uses: actions/download-artifact@v3
with:
name: forgejo-deb-${{ steps.ciprep.outputs.artifactlabel }}
- run: ./.ci-make.sh test-userinst-prep
2024-06-15 11:52:44 +10:00
- run: ./.ci-make.sh install-run-test ./forgejo_*_arm64.deb
2024-04-28 10:55:53 +10:00
publish-release-repo:
2024-06-15 12:20:47 +10:00
runs-on: bookworm
2024-04-28 10:55:53 +10:00
steps:
- uses: actions/checkout@v4
- name: actions prep
id: ciprep
run: ./.ci-make.sh actions-prep
- uses: actions/download-artifact@v3
with:
name: forgejo-deb-${{ steps.ciprep.outputs.artifactlabel }}
- uses: crystal/install-jq-action@v2.1.0
- run: mkdir forgejo-release
- run: mv *.deb *.deb.sha256 forgejo-release/
2024-06-15 12:00:52 +10:00
2024-06-15 13:37:49 +10:00
- uses: actions/forgejo-release@main
2024-04-28 10:55:53 +10:00
with:
direction: upload
2024-06-15 12:11:46 +10:00
url: https://git.alexjanka.com
token: ${{ secrets.PACKAGING_TOKEN }}
2024-04-28 15:42:48 +10:00
release-dir: forgejo-release
2024-04-28 10:55:53 +10:00
- name: Debian package registry publish
env:
2024-06-15 12:11:46 +10:00
FORGEJO_SITE: https://git.alexjanka.com
FORGEJO_OWNER: alex
DEBIAN_DIST: testing
DEBIAN_COMPONENT: forgejo
FORGEJO_KEY: ${{ secrets.PACKAGING_TOKEN }}
2024-04-28 10:55:53 +10:00
run: |
cd forgejo-release
../.ci-forgejo-apt.sh *.deb
cd ..