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: container naming #20

Merged
merged 3 commits into from
Dec 6, 2024
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
1 change: 1 addition & 0 deletions .github/workflows/containers.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ jobs:
# MONDOO_SERVICE_ACCOUNT: "${{ fromJson(secrets.VAULT_KV_1D187965_OP_MONDOO_PACKER_AGENT).password }}"
with:
dockerfile: "${{ matrix.container }}/Dockerfile"
image_name: "${{ github.repository }}/${{matrix.container}}"
score: 50
platforms: "linux/amd64, linux/arm64"
release: false
5 changes: 4 additions & 1 deletion go/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@

#first stage - building golang artifact
FROM golang:1.20.12-alpine as builder
FROM golang:1.20.12-alpine AS builder
WORKDIR /src
COPY . .
RUN go mod download
RUN CGO_ENABLED=0 go build -o app .

# output container ...
FROM debian:buster-slim

COPY --from=builder /src/app /bin/app

EXPOSE 6000

CMD ["/bin/app"]
2 changes: 1 addition & 1 deletion kubernetes/go-events.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ spec:
spec:
containers:
- name: go-events
image: mati007thm/dapr-distributed-calendar_go-events:manual
image: ghcr.io/infralovers/12-factor-app-go
env:
- name: APP_PORT
value: "6000"
Expand Down
2 changes: 1 addition & 1 deletion kubernetes/node-controller.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ spec:
spec:
containers:
- name: controller
image: mati007thm/dapr-distributed-calendar_controller:manual
image: ghcr.io/infralovers/12-factor-app-node
env:
- name: APP_PORT
value: "3000"
Expand Down
2 changes: 1 addition & 1 deletion kubernetes/python-messages.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ spec:
spec:
containers:
- name: messages
image: mati007thm/dapr-distributed-calendar_messages:manual
image: ghcr.io/infralovers/12-factor-app-python
env:
- name: "APP_PORT"
value: "5000"
Expand Down
1 change: 1 addition & 0 deletions node/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,5 @@ COPY . .
RUN npm install

EXPOSE 3000

CMD [ "node", "--require", "./instrumentation.js", "node_controller.js"]
10 changes: 5 additions & 5 deletions python/Dockerfile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
FROM python:3.11-alpine

COPY . /app
WORKDIR /app
# Install build dependencies
RUN apk add --no-cache gcc g++

RUN pip3 install -r /app/requirements.txt

RUN apk del gcc g++
RUN apk add --virtual build-deps --no-cache gcc g++ \
&& pip3 install -r /app/requirements.txt \
&& apk del build-deps

EXPOSE 5000

ENTRYPOINT ["python", "messages.py"]
Loading