Skip to content

Commit

Permalink
Removed user and group (#82)
Browse files Browse the repository at this point in the history
* added /bin/sh to dockerfiles

* changed scratch to alpine for final image

* removed unnecessary COPY from dockerfiles

* removed group and user (cedille-user)
  • Loading branch information
ThomasCardin authored Nov 26, 2023
1 parent b728f1d commit 11a427f
Show file tree
Hide file tree
Showing 3 changed files with 0 additions and 18 deletions.
6 changes: 0 additions & 6 deletions cmd/calidum-rotae-service/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ COPY . ./
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 \
go build -o ./calidum_rotae_service ./cmd/calidum-rotae-service/main.go

# Add user & group
RUN addgroup -S cedille-group && \
adduser -S cedille-user -G cedille-group

# Step 2 - import necessary files to run program.
FROM alpine

Expand All @@ -31,6 +27,4 @@ ENV CALIDUM_ROTAE_SERVICE_API_KEY=$CALIDUM_ROTAE_SERVICE_API_KEY
# Otherwise, pass the path to the certificate file.
ENV CERTIFICATE_FILE_PATH=$CERTIFICATE_FILE_PATH

USER cedille-user

ENTRYPOINT ["/calidum_rotae_service"]
6 changes: 0 additions & 6 deletions cmd/discord-provider/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ COPY . ./
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 \
go build -o ./discord_provider ./cmd/discord-provider/main.go

# Add user & group
RUN addgroup -S cedille-group && \
adduser -S cedille-user -G cedille-group

# Step 2 - import necessary files to run program.
FROM alpine

Expand All @@ -27,6 +23,4 @@ COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certifi

ENV DISCORD_WEBHOOK_URL=$DISCORD_WEBHOOK_URL

USER cedille-user

ENTRYPOINT ["/discord_provider"]
6 changes: 0 additions & 6 deletions cmd/email-provider/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -15,10 +15,6 @@ COPY . ./
RUN CGO_ENABLED=0 GOOS=linux GOARCH=amd64 \
go build -o ./email_provider ./cmd/email-provider/main.go

# Add user & group
RUN addgroup -S cedille-group && \
adduser -S cedille-user -G cedille-group

# Step 2 - import necessary files to run program.
FROM alpine

Expand All @@ -32,6 +28,4 @@ ENV EMAIL_TO_ADDRESS=$EMAIL_TO_ADDRESS
ENV EMAIL_SUBJECT=$EMAIL_SUBJECT
ENV EMAIL_SENDGRID_API_KEY=$EMAIL_SENDGRID_API_KEY

USER cedille-user

ENTRYPOINT ["/email_provider"]

0 comments on commit 11a427f

Please sign in to comment.