Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix Docker images building #27

Merged
merged 3 commits into from
Mar 3, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
38 changes: 19 additions & 19 deletions .github/workflows/ferretdb_packages.yml
Original file line number Diff line number Diff line change
Expand Up @@ -220,25 +220,25 @@ jobs:
OUTPUT='type=docker'
TAGS='${{ steps.version.outputs.docker_production_tag_flags }}'

# - name: Login to Docker Hub
# uses: docker/login-action@v3
# with:
# username: ferretdbbot
# password: ${{ secrets.DOCKER_HUB_TOKEN }}

# - name: Login to GitHub Container Registry
# uses: docker/login-action@v3
# with:
# registry: ghcr.io
# username: ${{ github.actor }}
# password: ${{ secrets.GITHUB_TOKEN }}

# - name: Login to Quay.io
# uses: docker/login-action@v3
# with:
# registry: quay.io
# username: ferretdbbot
# password: ${{ secrets.QUAY_TOKEN }}
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ferretdbbot
password: ${{ secrets.DOCKER_HUB_TOKEN }}

- name: Login to GitHub Container Registry
uses: docker/login-action@v3
with:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Login to Quay.io
uses: docker/login-action@v3
with:
registry: quay.io
username: ferretdbbot
password: ${{ secrets.QUAY_TOKEN }}

- name: Build and push development Docker images
if: steps.version.outputs.docker_development_tag_flags != ''
Expand Down
2 changes: 1 addition & 1 deletion ferretdb_packaging/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ docker-build:
test -n "$(OUTPUT)" || (echo "OUTPUT not set" && false)
test -n "$(TAGS)" || (echo "TAGS not set" && false)
docker buildx build --builder=documentdb \
--file=ferretdb_packaging/$(TARGET).Dockerfile \
--file=$(FILE).Dockerfile \
--build-arg='POSTGRES_VERSION=$(POSTGRES_VERSION)' \
--build-arg='DOCUMENTDB_VERSION=$(DOCUMENTDB_VERSION)' \
--platform=linux/amd64 \
Expand Down
4 changes: 3 additions & 1 deletion ferretdb_packaging/development.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
# syntax=docker/dockerfile:1

ARG POSTGRES_VERSION
ARG DOCUMENTDB_VERSION

FROM postgres:${POSTGRES_VERSION} AS development

ARG POSTGRES_VERSION
ARG DOCUMENTDB_VERSION

RUN --mount=type=cache,sharing=locked,target=/var/cache/apt <<EOF
set -ex

Expand Down
4 changes: 3 additions & 1 deletion ferretdb_packaging/production.Dockerfile
Original file line number Diff line number Diff line change
@@ -1,10 +1,12 @@
# syntax=docker/dockerfile:1

ARG POSTGRES_VERSION
ARG DOCUMENTDB_VERSION

FROM postgres:${POSTGRES_VERSION} AS production

ARG POSTGRES_VERSION
ARG DOCUMENTDB_VERSION

RUN --mount=type=cache,sharing=locked,target=/var/cache/apt <<EOF
set -ex

Expand Down
Loading