Skip to content
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
24 changes: 0 additions & 24 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -51,27 +51,3 @@ jobs:

- name: Verify build
run: poetry run poe run

build-python:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Set up Python 3.11
uses: actions/setup-python@v4
with:
python-version: 3.11

- name: Install poetry
run: |
curl -sSL https://install.python-poetry.org | python3 -

- name: Install dependencies
run: |
echo "$HOME/.local/bin" >> $GITHUB_PATH
poetry install --with=dev

- name: Build Docker container
run: poetry run poe build:docker-python

- name: Verify build
run: poetry run poe run:docker-python
26 changes: 26 additions & 0 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,32 @@ jobs:
docker push quay.io/mynth/docker-vault-cli:latest
if: github.ref == 'refs/heads/main'

publish-arm:
runs-on: ubuntu-latest
timeout-minutes: 10
steps:
- name: Login to Quay.io
uses: docker/login-action@v2
with:
registry: quay.io
username: ${{ secrets.QUAY_ID }}
password: ${{ secrets.QUAY_PW }}

- name: Checkout repository
uses: actions/checkout@v3

- name: Build docker-vault-cli container
run: docker build --platform linux/arm64 -t docker-vault-cli .

- name: Publish container
run: |
TAG=$(git rev-parse --short HEAD)
docker tag docker-vault-cli quay.io/mynth/docker-vault-cli:arm-$TAG
docker tag docker-vault-cli quay.io/mynth/docker-vault-cli:arm-latest
docker push quay.io/mynth/docker-vault-cli:arm-$TAG
docker push quay.io/mynth/docker-vault-cli:arm-latest
if: github.ref == 'refs/heads/main'

publish-python:
runs-on: ubuntu-latest
timeout-minutes: 10
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ FROM quay.io/mynth/python:dev as builder
USER root
# hadolint ignore=DL3008,DL3015
RUN apt-get update -qq && \
apt-get install -y binutils python3.11-dev
apt-get install -y binutils python3.12-dev
USER monty
COPY poetry.lock pyproject.toml /app/
RUN install-poetry-app src && \
Expand All @@ -20,5 +20,5 @@ RUN mv dist/vault-cli /usr/local/bin/
USER monty

# Create final image with vault-cli binary
FROM ubuntu:22.04
FROM ubuntu:24.04
COPY --from=builder /usr/local/bin/vault-cli /usr/local/bin/vault-cli
24 changes: 24 additions & 0 deletions arm64.Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
FROM quay.io/mynth/python:dev-arm as builder

# Install dependencies
USER root
# hadolint ignore=DL3008,DL3015
RUN apt-get update -qq && \
apt-get install -y binutils python3.12-dev
USER monty
COPY poetry.lock pyproject.toml /app/
RUN install-poetry-app src && \
poetry install --with=dev

# Build vault-cli
COPY src /app/src
RUN poe build:vault-cli

# Save binary
USER root
RUN mv dist/vault-cli /usr/local/bin/
USER monty

# Create final image with vault-cli binary
FROM ubuntu:24.04
COPY --from=builder /usr/local/bin/vault-cli /usr/local/bin/vault-cli
Loading