22 lines
1.1 KiB
YAML
22 lines
1.1 KiB
YAML
pipeline:
|
|
build:
|
|
image: registry.i.wit.com/toby/packager:1.3
|
|
environment:
|
|
- SHELL=/bin/bash
|
|
- DEBNAME=wit-network-config
|
|
commands:
|
|
- echo Building ${DRONE_BRANCH/master/experimental}
|
|
- apt-get update
|
|
- apt-get install -y sed strongswan frr isc-dhcp-client systemd
|
|
- echo "${DEBNAME} (2.0.$(date +%Y.%m.%d.%H.%M)) unstable; urgency=low\n\n$(git log --format=" * %s")\n\n -- wit <netops@wit.com> $(date -R)" >debian/changelog
|
|
- dpkg-buildpackage --no-sign
|
|
- ls -lha ../${DEBNAME}_*_all.deb
|
|
- echo "$SSH_KEY" >/tmp/id_rsa
|
|
- chmod 600 /tmp/id_rsa
|
|
- scp -i /tmp/id_rsa -o StrictHostKeyChecking=no ../${DEBNAME}_*_all.deb debcore@mirrors.wit.com:/data/incoming/${DRONE_BRANCH/master/experimental}
|
|
secrets: [ ssh_key ]
|
|
branches:
|
|
- master
|
|
- staging
|
|
- main
|