Direct generation of pages #79
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
name: stable build | |
on: | |
push: | |
branches: [ stable ] | |
schedule: | |
- cron: '27 1 3 * *' # monthly build on 1st of each month, 1:27AM | |
jobs: | |
build: | |
runs-on: ubuntu-20.04 | |
strategy: | |
fail-fast: false | |
matrix: | |
distrib: [ debian, fedora, ubuntu ] | |
steps: | |
- name: Checkout packages | |
uses: actions/checkout@v4 | |
with: | |
ref: "stable" | |
- name: Checkout builder script | |
uses: actions/checkout@v4 | |
with: | |
repository: jbigot/pkg_builder | |
path: pkg_builder | |
- name: Setup python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: '3.8' | |
- name: Install deps | |
run: | | |
echo ${{ secrets.GITHUB_TOKEN }} | docker login ghcr.io -u ${{ github.actor }} --password-stdin | |
curl -o - https://www.aptly.info/pubkey.txt | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/aptly.gpg > /dev/null | |
echo "deb http://repo.aptly.info/ squeeze main" | sudo tee /etc/apt/sources.list.d/aptly.list | |
sudo apt-get update | |
sudo apt-get upgrade | |
sudo apt-get install devscripts equivs aptly | |
pip3.8 install -r pkg_builder/requirements.txt | |
- name: Build packages | |
env: | |
KEY_PASSPHRASE: ${{ secrets.KEY_PASSPHRASE }} | |
DISTRIB: ${{ matrix.distrib }} | |
run: | | |
sed "s%pdidev/repo/%pdidev/repo/%g" -i build.conf | |
mkdir ${DISTRIB} | |
echo '<html><body>hello</body></html>' > ${DISTRIB}/index.html | |
#python3.8 pkg_builder/pkgbuild -D ${DISTRIB} -j 3 -p "${KEY_PASSPHRASE}" | |
- name: Upload artifact | |
uses: actions/upload-artifact@v4 | |
with: | |
name: ${{ matrix.distrib }} | |
path: ./${{ matrix.distrib }} | |
merge: | |
needs: build | |
runs-on: ubuntu-20.04 | |
steps: | |
- name: Download artifact | |
uses: actions/download-artifact@v4 | |
- name: Upload single artifact | |
uses: actions/upload-pages-artifact@v3 | |
with: | |
path: | | |
debian | |
fedora | |
ubuntu | |
publish: | |
needs: merge | |
permissions: | |
pages: write | |
id-token: write | |
environment: | |
name: github-pages | |
url: ${{ steps.deployment.outputs.page_url }} | |
runs-on: ubuntu-latest | |
steps: | |
- name: Deploy to GitHub Pages | |
id: deployment | |
uses: actions/deploy-pages@v4 |