CI: use brenard/aptly-publish image for publish-apt job
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
ci/woodpecker/tag/woodpecker Pipeline was successful

This commit is contained in:
Benjamin Renard 2022-08-01 23:16:12 +02:00
parent 6aefda385c
commit 9c9773f489

View file

@ -54,19 +54,17 @@ pipeline:
publish-apt: publish-apt:
group: publish group: publish
image: brenard/curl image: brenard/aptly-publish
when: when:
event: tag event: tag
commands: settings:
- curl -u $APT_CREDS -X POST -F file=@$( ls dist/gitdch_*_all.deb ) $APT_API_URL/files/gitdch api_url:
- curl -u $APT_CREDS -X POST -F file=@$( ls dist/gitdch_*.buildinfo ) $APT_API_URL/files/gitdch from_secret: apt_api_url
- curl -u $APT_CREDS -X POST -F file=@$( ls dist/gitdch_*.changes ) $APT_API_URL/files/gitdch api_username:
- curl -u $APT_CREDS -X POST -F file=@$( ls dist/gitdch_*.dsc ) $APT_API_URL/files/gitdch from_secret: apt_api_username
- curl -u $APT_CREDS -X POST -F file=@$( ls dist/gitdch_*.tar.gz ) $APT_API_URL/files/gitdch api_password:
- curl -u $APT_CREDS -X POST $APT_API_URL/repos/$APT_REPO_NAME/include/gitdch from_secret: apt_api_password
- APT_SNAP_NAME=$(date +%s)_$APT_REPO_NAME repo_name:
- > from_secret: apt_repo_name
curl -u $APT_CREDS -X POST -H 'Content-Type: application/json' --data "{\"Name\":\"$APT_SNAP_NAME\"}" $APT_API_URL/repos/$APT_REPO_NAME/snapshots path: dist
- > source_name: gitdch
curl -u $APT_CREDS -X PUT -H 'Content-Type: application/json' --data "{\"Snapshots\": [{\"Component\": \"main\", \"Name\": \"$APT_SNAP_NAME\"}]}" $APT_API_URL/publish/:./$APT_REPO_NAME
secrets: [ apt_api_url, apt_creds, apt_repo_name ]