publish-petclinic-benchmark-image.yml 989 B

123456789101112131415161718192021222324252627282930313233343536
  1. name: Publish PetClinic benchmark image
  2. on:
  3. push:
  4. paths:
  5. - "benchmark-overhead/Dockerfile-petclinic-base"
  6. branches:
  7. - main
  8. workflow_dispatch:
  9. jobs:
  10. publish:
  11. runs-on: ubuntu-latest
  12. permissions:
  13. packages: write
  14. contents: read
  15. steps:
  16. - uses: actions/checkout@v4
  17. - uses: docker/setup-buildx-action@v3
  18. - name: Login to GitHub container registry
  19. uses: docker/login-action@v3
  20. with:
  21. registry: ghcr.io
  22. username: ${{ github.repository_owner }}
  23. password: ${{ secrets.GITHUB_TOKEN }}
  24. - name: Create timestamp for docker image tag
  25. run: echo "TS=$(date +'%Y%m%d%H%M%S')" >> $GITHUB_ENV
  26. - name: Push to GitHub packages
  27. uses: docker/build-push-action@v5
  28. with:
  29. push: true
  30. file: benchmark-overhead/Dockerfile-petclinic-base
  31. tags: ghcr.io/open-telemetry/opentelemetry-java-instrumentation/petclinic-rest-base:${{ env.TS }}