From 73f816c56031b8d35321e1fe17b90a5ff3bfb410 Mon Sep 17 00:00:00 2001 From: Nick Le Large Date: Fri, 25 Oct 2024 09:26:21 +0000 Subject: [PATCH] Add stages to current Dockerfile --- .github/workflows/build-and-push-docker.yaml | 3 ++- Dockerfile | 5 ++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/.github/workflows/build-and-push-docker.yaml b/.github/workflows/build-and-push-docker.yaml index 4edc8fca..4a8d5491 100644 --- a/.github/workflows/build-and-push-docker.yaml +++ b/.github/workflows/build-and-push-docker.yaml @@ -26,8 +26,9 @@ jobs: password: ${{ secrets.GITHUB_TOKEN }} - name: Build and push Docker image - uses: docker/build-push-action@v5 + uses: docker/build-push-action@v6 with: push: true tags: ghcr.io/kit-mrt/arbitration_graphs:latest + target: install diff --git a/Dockerfile b/Dockerfile index 769499f4..f5bf435a 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,4 +1,4 @@ -FROM ubuntu:22.04 +FROM ubuntu:22.04 AS base ARG DEBIAN_FRONTEND=noninteractive @@ -25,6 +25,9 @@ RUN git clone https://github.com/KIT-MRT/util_caching.git /tmp/util_caching && \ # Install arbitration_graphs COPY . /tmp/arbitration_graphs + +FROM base AS install + RUN mkdir /tmp/arbitration_graphs/build && \ cd /tmp/arbitration_graphs/build && \ cmake .. && \