fix(ci): pin docker api version for release builds refs NOISSUE

This commit is contained in:
2026-04-10 19:58:38 +02:00
parent 6ee1c46826
commit e9dc1ede55
4 changed files with 10 additions and 3 deletions

View File

@@ -4,6 +4,7 @@ permissions:
env: env:
SKIP_MAKE_SETUP_CHECK: 'true' SKIP_MAKE_SETUP_CHECK: 'true'
DOCKER_API_VERSION: '1.43'
on: on:
push: push:
@@ -49,11 +50,15 @@ jobs:
fi fi
- name: Login to Gitea container registry - name: Login to Gitea container registry
uses: docker/login-action@v3 uses: docker/login-action@v3
env:
DOCKER_API_VERSION: ${{ env.DOCKER_API_VERSION }}
with: with:
username: gitearobot username: gitearobot
password: ${{ secrets.PACKAGE_GITEA_PAT }} password: ${{ secrets.PACKAGE_GITEA_PAT }}
registry: git.disi.dev registry: git.disi.dev
- name: Build and publish - name: Build and publish
env:
DOCKER_API_VERSION: ${{ env.DOCKER_API_VERSION }}
run: | run: |
REPOSITORY_OWNER=$(echo "$GITHUB_REPOSITORY" | awk -F '/' '{print $1}' | tr '[:upper:]' '[:lower:]') REPOSITORY_OWNER=$(echo "$GITHUB_REPOSITORY" | awk -F '/' '{print $1}' | tr '[:upper:]' '[:lower:]')
REPOSITORY_NAME=$(echo "$GITHUB_REPOSITORY" | awk -F '/' '{print $2}' | tr '-' '_') REPOSITORY_NAME=$(echo "$GITHUB_REPOSITORY" | awk -F '/' '{print $2}' | tr '-' '_')

View File

@@ -40,4 +40,4 @@ HEALTHCHECK --interval=30s --timeout=3s --start-period=5s --retries=3 \
CMD curl -f http://localhost:8000/health || exit 1 CMD curl -f http://localhost:8000/health || exit 1
# Run application # Run application
CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000", "--reload"]"] CMD ["uvicorn", "main:app", "--host", "0.0.0.0", "--port", "8000", "--reload"]

View File

@@ -1,5 +1,7 @@
.ONESHELL: .ONESHELL:
DOCKER_API_VERSION ?= 1.43
.PHONY: issetup .PHONY: issetup
issetup: issetup:
@[ -f .git/hooks/commit-msg ] || [ -z ${SKIP_MAKE_SETUP_CHECK+x} ] || (echo "You must run 'make setup' first to initialize the repo!" && exit 1) @[ -f .git/hooks/commit-msg ] || [ -z ${SKIP_MAKE_SETUP_CHECK+x} ] || (echo "You must run 'make setup' first to initialize the repo!" && exit 1)
@@ -42,7 +44,7 @@ release: issetup ## Create a new tag for release.
.PHONY: build .PHONY: build
build: issetup ## Create a new tag for release. build: issetup ## Create a new tag for release.
@docker build -t ai-software-factory:$(cat ai-software-factory/VERSION) -f Containerfile . @DOCKER_API_VERSION=$(DOCKER_API_VERSION) docker build -t ai-software-factory:$(cat ai_software_factory/VERSION) -f Containerfile .
# This project has been generated from rochacbruno/python-project-template # This project has been generated from rochacbruno/python-project-template
#igest__ = 'rochacbruno' #igest__ = 'rochacbruno'

View File

@@ -65,7 +65,7 @@ TELEGRAM_CHAT_ID=your_chat_id
```bash ```bash
# Build Docker image # Build Docker image
docker build -t ai-software-factory -f Containerfile . DOCKER_API_VERSION=1.43 docker build -t ai-software-factory -f Containerfile .
# Run with Docker Compose # Run with Docker Compose
docker-compose up -d docker-compose up -d