~sbaildon/transmission

16b894572bfadd322a0ca33b2624ad66a7b1a54f — Sean Baildon 11 months ago 3b0f1b9
build file
1 files changed, 32 insertions(+), 0 deletions(-)

A .builds/container.yml
A .builds/container.yml => .builds/container.yml +32 -0
@@ 0,0 1,32 @@
image: alpine/edge
packages:
  - podman
  - buildah
environment:
  project: transmission
  registry: registry.b5n.dev
sources:
  - git@git.sr.ht:~sbaildon/transmission
secrets:
  - 11e422b9-a23f-40f8-9668-9b74373da4b7 # gitconfig
  - 7f17d22b-0e3e-49be-b4dc-1e4a99343886 # b5n.dev container registry
tasks:
  - gather_info: |
      cd ${project}
      echo export PROJECT_REVISION=$(git rev-parse --short HEAD) >> ~/.buildenv
      echo export BRANCH=$(git name-rev --name-only HEAD) >> ~/.buildenv
  - container: |
      cd ${project}
      buildah build-using-dockerfile \
        --annotation org.opencontainers.image.revision=${PROJECT_REVISION} \
        --annotation org.opencontainers.image.created=$(date -u +"%Y-%m-%dT%H:%M:%SZ") \
        --annotation org.opencontainers.image.source="https://git.sr.ht/~sbaildon/transmission" \
        --annotation org.opencontainers.image.url="https://github.com/transmission/transmission" \
        --manifest ${registry}/${project}:${PROJECT_REVISION} \
        --platform=linux/amd64 .
  - push: |
      buildah manifest \
        push \
        --all \
        ${registry}/${project}:${PROJECT_REVISION} \
        docker://${registry}/${project}:${PROJECT_REVISION}