2023-12-26 10:02:13 +01:00
|
|
|
clone:
|
|
|
|
git:
|
2024-01-28 03:00:26 +01:00
|
|
|
image: woodpeckerci/plugin-git:2.5.0
|
2023-12-26 10:02:13 +01:00
|
|
|
settings:
|
|
|
|
partial: false
|
|
|
|
depth: 10
|
|
|
|
|
2023-11-26 12:31:28 +01:00
|
|
|
steps:
|
2022-11-16 22:07:36 +01:00
|
|
|
build:
|
2023-12-26 09:46:12 +01:00
|
|
|
image: archlinux/archlinux:base-devel
|
2022-11-16 22:07:36 +01:00
|
|
|
pull: true
|
2022-07-14 09:51:09 +02:00
|
|
|
volumes:
|
2023-05-29 16:14:46 +02:00
|
|
|
- /mnt/archlinux/nyyu:/repo
|
2022-07-14 09:51:09 +02:00
|
|
|
commands:
|
2023-05-29 16:14:46 +02:00
|
|
|
- cp -f conf/{makepkg,pacman}.conf /etc/
|
|
|
|
- cat conf/pacman-conf.d-noextract.conf >> /etc/pacman.conf
|
|
|
|
- pacman-key --init
|
|
|
|
- pacman -Syu git jq pacman-contrib pandoc-bin unzip --noconfirm
|
|
|
|
- useradd build -m
|
|
|
|
- "echo 'build ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers"
|
2023-12-09 14:19:53 +01:00
|
|
|
- mkdir /build
|
|
|
|
- chown -R build:build . /build
|
2023-05-29 16:14:46 +02:00
|
|
|
- sudo -u build --preserve-env=PGP_KEY,PGP_PWD,PGP_ID sh -c 'mkdir ~/.gnupg && echo -e "default-cache-ttl 3600\nallow-preset-passphrase" > ~/.gnupg/gpg-agent.conf && echo "$PGP_KEY" | gpg --import --no-tty --batch --yes && echo "$PGP_PWD" | /usr/lib/gnupg/gpg-preset-passphrase --preset $PGP_ID'
|
2023-12-09 14:19:53 +01:00
|
|
|
- sudo -u build --preserve-env=CI_REPO_CLONE_URL,CI_COMMIT_BRANCH,CI_PREV_COMMIT_SHA,GIT_PASSWORD sh -c './build.sh'
|
2022-11-16 22:07:36 +01:00
|
|
|
secrets: [pgp_id, pgp_key, pgp_pwd, git_password]
|
|
|
|
when:
|
2022-11-21 18:16:47 +01:00
|
|
|
branch: master
|
2023-05-29 16:14:46 +02:00
|
|
|
event: [push, cron, tag, manual]
|