publiccode.si/.drone.yml

34 lines
1.4 KiB
YAML
Raw Normal View History

2017-06-13 09:08:46 +02:00
pipeline:
2017-09-08 11:39:18 +02:00
syntaxcheck:
image: publysher/hugo
commands:
2017-09-12 10:00:13 +02:00
- cd site; ./build/build.sh syntax
2017-09-08 11:39:18 +02:00
2017-06-13 09:08:46 +02:00
deploy:
image: docker:dind
2017-06-13 09:10:11 +02:00
commands:
# Get docker-compose
- wget -q -O /usr/local/bin/docker-compose https://github.com/docker/compose/releases/download/1.22.0/docker-compose-$(uname -s)-$(uname -m)
# Make it executable
- chmod 700 /usr/local/bin/docker-compose
# Download and install glibc (Alpine comes with musl libc) because docker-compose relies on it
- wget -q https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.27-r0/glibc-2.27-r0.apk https://github.com/sgerrand/alpine-pkg-glibc/releases/download/2.27-r0/glibc-bin-2.27-r0.apk
- wget -q -O /etc/apk/keys/sgerrand.rsa.pub https://alpine-pkgs.sgerrand.com/sgerrand.rsa.pub
- apk add -q --update glibc-2.27-r0.apk glibc-bin-2.27-r0.apk
- apk add -q git
# Clone the git remository
# Make the signatures file available to the PMPC website
# Build the docker container
# Clean things up
- git clone https://git.fsfe.org/pmpc/website.git /tmp/pmpc-build && cd /tmp/pmpc-build/ && cp /tmp/signatures/signatures.json site/data/signatures/signatures.json && docker build -t pmpc .
# Run docker compose
- docker-compose up -d
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- /srv/forms/pmpc:/tmp/signatures:ro
2017-06-13 08:54:28 +02:00
when:
2018-04-11 14:55:10 +02:00
event: [push, tag, deployment]
2017-06-13 08:54:28 +02:00
branch: master