Skip to content

Commit e8d302c

Browse files
committed
use docker approach instead
1 parent d7beffb commit e8d302c

File tree

2 files changed

+18
-11
lines changed

2 files changed

+18
-11
lines changed

.github/workflows/container-validation-backends.yml

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,14 @@ jobs:
7575
run: |
7676
cd deploy/cloud/operator
7777
docker build --target tester --progress=plain --build-arg DOCKER_PROXY=${ECR_HOSTNAME}/dockerhub/ .
78+
79+
- name: Check for uncommitted changes
80+
shell: bash
81+
env:
82+
ECR_HOSTNAME: ${{ secrets.AWS_ACCOUNT_ID }}.dkr.ecr.${{ secrets.AWS_DEFAULT_REGION }}.amazonaws.com
83+
run: |
84+
cd deploy/cloud/operator
85+
docker build --target check --progress=plain --build-arg DOCKER_PROXY=${ECR_HOSTNAME}/dockerhub/ .
7886
- name: Build Container
7987
id: build-image
8088
shell: bash
@@ -87,16 +95,6 @@ jobs:
8795
--build-arg DOCKER_PROXY=${ECR_HOSTNAME}/dockerhub/ \
8896
-f Dockerfile \
8997
-t dynamo-operator:latest .
90-
91-
- name: Check for uncommitted changes
92-
shell: bash
93-
env:
94-
ECR_HOSTNAME: ${{ secrets.AWS_ACCOUNT_ID }}.dkr.ecr.${{ secrets.AWS_DEFAULT_REGION }}.amazonaws.com
95-
run: |
96-
sudo apt-get update && sudo apt-get install -y make
97-
cd deploy/cloud/operator
98-
make check
99-
10098
- name: Docker Tag and Push
10199
uses: ./.github/actions/docker-tag-push
102100
with:

deploy/cloud/operator/Dockerfile

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,16 @@ RUN apt-get update && apt-get install -y make && apt-get clean && rm -rf /var/li
4343
# Run tests using Makefile
4444
RUN make test
4545

46-
# Build stage - depends on successful lint and test
46+
# Check stage
47+
FROM base AS checker
48+
49+
# Install make if not present
50+
RUN apt-get update && apt-get install -y make && apt-get clean && rm -rf /var/lib/apt/lists/*
51+
52+
# Run check using Makefile
53+
RUN make check
54+
55+
# Build stage - depends on successful lint, test and check
4756
FROM base AS builder
4857

4958
# Build the binary

0 commit comments

Comments
 (0)