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

build: remove base image multi-stage build #129

Merged
merged 2 commits into from
Jan 8, 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
23 changes: 5 additions & 18 deletions .github/workflows/build-base-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,41 +43,28 @@ jobs:
echo "Project version: ${project_version}"
echo "value=${project_version}" >> $GITHUB_OUTPUT

build-part1-of-base-image:
name: Build Part 1 of Base Image
build-and-push-and-tag-base-image:
name: Build and Push and Tag Base Image with Version
needs:
- prepare-environment
uses: ./.github/workflows/build-image.yml
with:
project_name: ${{ needs.prepare-environment.outputs.project_name }}
project_version: ${{ needs.prepare-environment.outputs.project_version }}
push: false
target: base1
secrets: inherit

build-part2-and-push-and-tag-base-image:
name: Build Part 2 and Push and Tag Base Image with Version
needs:
- prepare-environment
- build-part1-of-base-image
uses: ./.github/workflows/build-image.yml
with:
project_name: ${{ needs.prepare-environment.outputs.project_name }}
project_version: ${{ needs.prepare-environment.outputs.project_version }}
push: true
target: base2
target: base
secrets: inherit

push-and-tag-base-image-as-latest:
if: github.event_name == 'release' && github.event.action == 'published'
name: Push and Tag Base Image as Latest
needs:
- prepare-environment
- build-part2-and-push-and-tag-base-image
- build-and-push-and-tag-base-image
uses: ./.github/workflows/build-image.yml
with:
project_name: ${{ needs.prepare-environment.outputs.project_name }}
project_version: latest
push: true
target: base2
target: base
secrets: inherit
4 changes: 1 addition & 3 deletions docker/development/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Apache License 2.0

FROM ubuntu:20.04 as base1
FROM ubuntu:20.04 as base

LABEL maintainer="lucas.bremond@gmail.com"

Expand Down Expand Up @@ -94,8 +94,6 @@ RUN curl -sS https://bootstrap.pypa.io/get-pip.py | python3.9 && \
curl -sS https://bootstrap.pypa.io/get-pip.py | python3.12 && \
curl -sS https://bootstrap.pypa.io/get-pip.py | python3.13

FROM base1 as base2

## Python tools

RUN apt-get update -y \
Expand Down
Loading