WIP: build production images
Some checks failed
Build Docker Images / build-and-push (push) Failing after 1m30s
Some checks failed
Build Docker Images / build-and-push (push) Failing after 1m30s
This commit is contained in:
53
.gitea/workflows/build.yml
Normal file
53
.gitea/workflows/build.yml
Normal file
@@ -0,0 +1,53 @@
|
||||
name: Build Docker Images
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
|
||||
concurrency:
|
||||
group: build-${{ github.ref }}
|
||||
cancel-in-progress: false
|
||||
|
||||
jobs:
|
||||
build-and-push:
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout code
|
||||
uses: https://github.com/actions/checkout@v4
|
||||
|
||||
- name: Set up Docker Buildx
|
||||
uses: https://github.com/docker/setup-buildx-action@v3
|
||||
|
||||
- name: Log in to Gitea Container Registry
|
||||
run: |
|
||||
echo "${{ secrets.REGISTRY_TOKEN }}" | docker login code.bim-it.pl -u "${{ secrets.REGISTRY_USER }}" --password-stdin
|
||||
|
||||
- name: Build and push API image (build artifacts)
|
||||
run: |
|
||||
docker buildx build \
|
||||
--platform linux/amd64 \
|
||||
-f BimAI.API/Dockerfile \
|
||||
-t code.bim-it.pl/bimai/bimai-api:build-${{ github.run_id }} \
|
||||
--push \
|
||||
.
|
||||
|
||||
- name: Build and push UI image (build artifacts)
|
||||
run: |
|
||||
docker buildx build \
|
||||
--platform linux/amd64 \
|
||||
-f BimAI.UI.Web/Dockerfile \
|
||||
-t code.bim-it.pl/bimai/bimai-ui:build-${{ github.run_id }} \
|
||||
--push \
|
||||
.
|
||||
|
||||
- name: Output build info
|
||||
run: |
|
||||
echo "## 🏗️ Docker Images Built" >> $GITHUB_STEP_SUMMARY
|
||||
echo "" >> $GITHUB_STEP_SUMMARY
|
||||
echo "**Build ID:** ${{ github.run_id }}" >> $GITHUB_STEP_SUMMARY
|
||||
echo "" >> $GITHUB_STEP_SUMMARY
|
||||
echo "Images pushed with tag: \`build-${{ github.run_id }}\`" >> $GITHUB_STEP_SUMMARY
|
||||
echo "" >> $GITHUB_STEP_SUMMARY
|
||||
echo "Use **Release** workflow to tokenize and tag as \`:prod\`" >> $GITHUB_STEP_SUMMARY
|
||||
Reference in New Issue
Block a user