aur/.drone.yml

38 lines
1.3 KiB
YAML
Raw Normal View History

2021-05-19 09:48:07 +02:00
kind: pipeline
type: docker
name: default
steps:
- name: build
2021-08-14 09:30:13 +02:00
pull: always
2021-06-04 07:44:48 +02:00
image: archlinux:base-devel
2021-05-19 09:48:07 +02:00
volumes:
- name: repo
path: /repo
commands:
2021-05-19 14:33:23 +02:00
- sed -i 's/# REPOSITORIES/[nyyu]\nServer = https:\\/\\/archlinux.nyyu.dev\\/nyyu\nSigLevel = Never/' /etc/pacman.conf
2021-11-13 23:21:45 +01:00
- pacman -Syu git jq pacman-contrib pandoc-bin --noconfirm
2021-05-19 17:52:27 +02:00
- mv /etc/pacman.conf.pacnew /etc/pacman.conf
- sed -i 's/# REPOSITORIES/[nyyu]\nServer = https:\\/\\/archlinux.nyyu.dev\\/nyyu\nSigLevel = Never/' /etc/pacman.conf
- sed -i 's/#PACKAGER=".*"/PACKAGER="nyyu <mail@nyyu.dev>"/' /etc/makepkg.conf
2021-05-19 11:26:24 +02:00
- useradd build -m
- "echo 'build ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers"
- chown -R build:build .
2021-08-20 07:09:29 +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'
- sudo -u build --preserve-env=DRONE_GIT_HTTP_URL,DRONE_SOURCE_BRANCH sh -c './build.sh'
2021-05-19 16:29:42 +02:00
environment:
PGP_KEY:
from_secret: PGP_KEY
2021-05-19 16:41:48 +02:00
PGP_PWD:
from_secret: PGP_PWD
PGP_ID:
from_secret: PGP_ID
2021-05-19 09:48:07 +02:00
volumes:
- name: repo
host:
path: /mnt/archlinux/nyyu
2022-01-06 16:00:58 +01:00
trigger:
branch:
- master