🚀 Release & Docker Build #13
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: "\U0001F680 Release & Docker Build" | |
| on: | |
| push: | |
| branches: [main] | |
| paths-ignore: | |
| - '.github/**' | |
| - '*.md' | |
| - 'docs/**' | |
| pull_request: | |
| branches: [main] | |
| paths: | |
| - 'src/**' | |
| - 'docker-compose*.yml' | |
| - '.dockerignore' | |
| workflow_dispatch: | |
| inputs: | |
| force-release: | |
| description: 'force create release' | |
| type: boolean | |
| default: false | |
| permissions: | |
| contents: write | |
| issues: write | |
| pull-requests: write | |
| packages: write | |
| security-events: write | |
| jobs: | |
| # ============================================ | |
| # Validation Jobs | |
| # ============================================ | |
| validate-compose: | |
| name: "\U0001F50D Validate Docker Compose" | |
| uses: bauer-group/automation-templates/.github/workflows/modules-validate-compose.yml@main | |
| with: | |
| compose-files: '["docker-compose-single.yml", "docker-compose-single-traefik.yml", "docker-compose-development.yml"]' | |
| env-file: '.env.example' | |
| # ============================================ | |
| # Release Job (only on main branch push) | |
| # ============================================ | |
| release: | |
| name: "\U0001F4E6 Create Semantic Release" | |
| needs: [validate-compose] | |
| if: | | |
| (github.event_name == 'push' || github.event_name == 'workflow_dispatch') && | |
| needs.validate-compose.result == 'success' | |
| uses: bauer-group/automation-templates/.github/workflows/modules-semantic-release.yml@main | |
| with: | |
| target-branch: 'main' | |
| dry-run: false | |
| force-release: ${{ inputs.force-release || false }} | |
| secrets: inherit | |
| # ============================================ | |
| # MinIO Server Docker Build Jobs | |
| # ============================================ | |
| docker-build-release: | |
| name: "\U0001F433 Build & Push MinIO Image" | |
| needs: release | |
| if: needs.release.outputs.release-created == 'true' | |
| uses: bauer-group/automation-templates/.github/workflows/docker-build.yml@main | |
| with: | |
| deploy-environment: 'production' | |
| publish-to: 'ghcr' | |
| ghcr-image-name: 'bauer-group/CS-MinIO/minio' | |
| docker-image-name: 'bauergroup/minio' | |
| release-version: ${{ needs.release.outputs.version }} | |
| image-tags: 'stable' | |
| update-dockerfile-version: true | |
| auto-tags: true | |
| latest-tag: true | |
| dockerfile-path: './src/minio/Dockerfile' | |
| docker-context: './src/minio' | |
| platforms: 'linux/amd64' | |
| push: true | |
| security-scan: false | |
| security-fail-on: 'CRITICAL' | |
| generate-sbom: true | |
| sync-dockerhub-readme: true | |
| secrets: inherit | |
| docker-build-pr: | |
| name: "\U0001F528 Validate MinIO Build (PR)" | |
| needs: [validate-compose] | |
| if: | | |
| github.event_name == 'pull_request' && | |
| needs.validate-compose.result == 'success' | |
| uses: bauer-group/automation-templates/.github/workflows/docker-build.yml@main | |
| with: | |
| publish-to: 'ghcr' | |
| ghcr-image-name: 'bauer-group/CS-MinIO/minio' | |
| auto-tags: true | |
| dockerfile-path: './src/minio/Dockerfile' | |
| docker-context: './src/minio' | |
| platforms: 'linux/amd64' | |
| push: false | |
| security-scan: false | |
| security-fail-on: 'CRITICAL' | |
| secrets: inherit | |
| # ============================================ | |
| # MinIO Init Docker Build Jobs | |
| # ============================================ | |
| docker-build-init-release: | |
| name: "\U0001F433 Build & Push Init Image" | |
| needs: release | |
| if: needs.release.outputs.release-created == 'true' | |
| uses: bauer-group/automation-templates/.github/workflows/docker-build.yml@main | |
| with: | |
| deploy-environment: 'production' | |
| publish-to: 'ghcr' | |
| ghcr-image-name: 'bauer-group/CS-MinIO/minio-init' | |
| docker-image-name: 'bauergroup/minio-init' | |
| release-version: ${{ needs.release.outputs.version }} | |
| image-tags: 'stable' | |
| update-dockerfile-version: true | |
| auto-tags: true | |
| latest-tag: true | |
| dockerfile-path: './src/minio-init/Dockerfile' | |
| docker-context: './src/minio-init' | |
| platforms: 'linux/amd64' | |
| push: true | |
| security-scan: false | |
| security-fail-on: 'CRITICAL' | |
| generate-sbom: true | |
| sync-dockerhub-readme: true | |
| secrets: inherit | |
| docker-build-init-pr: | |
| name: "\U0001F528 Validate Init Build (PR)" | |
| needs: [validate-compose] | |
| if: | | |
| github.event_name == 'pull_request' && | |
| needs.validate-compose.result == 'success' | |
| uses: bauer-group/automation-templates/.github/workflows/docker-build.yml@main | |
| with: | |
| publish-to: 'ghcr' | |
| ghcr-image-name: 'bauer-group/CS-MinIO/minio-init' | |
| auto-tags: true | |
| dockerfile-path: './src/minio-init/Dockerfile' | |
| docker-context: './src/minio-init' | |
| platforms: 'linux/amd64' | |
| push: false | |
| security-scan: false | |
| security-fail-on: 'CRITICAL' | |
| secrets: inherit | |
| # ============================================ | |
| # MinIO Console Docker Build Jobs | |
| # ============================================ | |
| docker-build-console-release: | |
| name: "\U0001F433 Build & Push Console Image" | |
| needs: release | |
| if: needs.release.outputs.release-created == 'true' | |
| uses: bauer-group/automation-templates/.github/workflows/docker-build.yml@main | |
| with: | |
| deploy-environment: 'production' | |
| publish-to: 'ghcr' | |
| ghcr-image-name: 'bauer-group/CS-MinIO/minio-console' | |
| docker-image-name: 'bauergroup/minio-console' | |
| release-version: ${{ needs.release.outputs.version }} | |
| image-tags: 'latest' | |
| update-dockerfile-version: true | |
| auto-tags: true | |
| latest-tag: true | |
| dockerfile-path: './src/minio-console/Dockerfile' | |
| docker-context: './src/minio-console' | |
| platforms: 'linux/amd64' | |
| push: true | |
| security-scan: false | |
| security-fail-on: 'CRITICAL' | |
| generate-sbom: true | |
| sync-dockerhub-readme: true | |
| secrets: inherit | |
| docker-build-console-pr: | |
| name: "\U0001F528 Validate Console Build (PR)" | |
| needs: [validate-compose] | |
| if: | | |
| github.event_name == 'pull_request' && | |
| needs.validate-compose.result == 'success' | |
| uses: bauer-group/automation-templates/.github/workflows/docker-build.yml@main | |
| with: | |
| publish-to: 'ghcr' | |
| ghcr-image-name: 'bauer-group/CS-MinIO/minio-console' | |
| auto-tags: true | |
| dockerfile-path: './src/minio-console/Dockerfile' | |
| docker-context: './src/minio-console' | |
| platforms: 'linux/amd64' | |
| push: false | |
| security-scan: false | |
| security-fail-on: 'CRITICAL' | |
| secrets: inherit |