trying to implement code signing support

This commit is contained in:
Jonas Heinrich 2020-12-01 16:08:57 +01:00
parent 565d4c3fcd
commit eddd26a51f

View File

@ -30,15 +30,8 @@ packaging:
signing:
stage: signing
image: nextcloud:fpm
script:
- apt update
- DEBIAN_FRONTEND="noninteractive" apt install -y wget apt-transport-https
- wget -q -O- https://packages.sury.org/php/apt.gpg | apt-key add -
- echo "deb https://packages.sury.org/php/ stretch main" | tee /etc/apt/sources.list.d/php.list
- apt-get update
- DEBIAN_FRONTEND="noninteractive" apt install -y php7.2 php7.2-gd php7.2-json php7.2-mysql php7.2-curl php7.2-intl php7.2-imagick php7.2-zip php7.2-xmlwriter php7.2-xmlreader php7.2-xml php7.2-mbstring php7.2-simplexml
- wget https://download.nextcloud.com/server/releases/nextcloud-20.0.2.tar.bz2
- tar xvf nextcloud-20.0.2.tar.bz2
- echo "-----BEGIN PRIVATE KEY-----" > sign.key
- echo $SIGN_KEY | tr " " "\n" >> sign.key
- echo "-----END PRIVATE KEY-----" >> sign.key
@ -46,7 +39,7 @@ signing:
- echo $SIGN_CRT | tr " " "\n" >> sign.crt
- echo "-----END CERTIFICATE-----" >> sign.crt
- tar xvf build/artifacts/radio.tar.gz
- php nextcloud/occ integrity:sign-app --path=$(pwd)/radio --privateKey=$(pwd)/sign.key --certificate=$(pwd)/sign.crt
- ./occ integrity:sign-app --path=$(pwd)/radio --privateKey=$(pwd)/sign.key --certificate=$(pwd)/sign.crt
- ls $(pwd)/radio/appinfo
- tar -czvf build/artifacts/radio.tar.gz radio
- rm -r sign.key sign.crt radio