-
Notifications
You must be signed in to change notification settings - Fork 22
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Modify Actions pipeline to push docker containers
- Loading branch information
1 parent
c6fe2ab
commit 085a8a4
Showing
7 changed files
with
189 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
FROM rust:1.70.0-slim AS builder | ||
|
||
FROM alpine:3.17 | ||
|
||
# for devel only | ||
RUN apk add --repository http://dl-cdn.alpinelinux.org/alpine/v3.17/main fuse lftp curl | ||
RUN apk add --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing curlftpfs | ||
|
||
# we could also RUN 'apk add ca-certificates', but we prefer to be consistent with the -minimal image | ||
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt | ||
|
||
# no security measures, run as root | ||
USER root | ||
RUN mkdir /unftp | ||
COPY --chmod=755 ./x86_64-unknown-linux-musl/unftp_x86_64-unknown-linux-musl /unftp/unftp | ||
WORKDIR /unftp | ||
CMD ["/unftp/unftp", "-vv"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
FROM rust:1.70.0-slim AS builder | ||
|
||
FROM alpine:3.17 | ||
|
||
# for devel only | ||
RUN apk add --repository http://dl-cdn.alpinelinux.org/alpine/v3.17/main fuse lftp curl | ||
RUN apk add --repository http://dl-cdn.alpinelinux.org/alpine/edge/testing curlftpfs | ||
|
||
# we could also RUN 'apk add ca-certificates', but we prefer to be consistent with the -minimal image | ||
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt | ||
COPY --from=redboxoss/scuttle:latest /scuttle /bin/scuttle | ||
|
||
# no security measures, run as root | ||
USER root | ||
RUN mkdir /unftp | ||
COPY --chmod=755 ./x86_64-unknown-linux-musl/unftp_x86_64-unknown-linux-musl /unftp/unftp | ||
WORKDIR /unftp | ||
CMD ["scuttle", "/unftp/unftp", "-vv"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
FROM rust:1.70.0-slim AS builder | ||
|
||
FROM alpine:latest | ||
|
||
# we could also RUN 'apk add ca-certificates', but we prefer to be consistent with the -minimal image | ||
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt | ||
COPY --from=redboxoss/scuttle:latest /scuttle /bin/scuttle | ||
# run as user for security | ||
RUN mkdir /unftp && mkdir -p /srv | ||
RUN addgroup -g 1010 unftp \ | ||
&& adduser -D -s /bin/sh -u 1010 -G unftp unftp \ | ||
&& chown -R unftp:unftp /unftp /srv | ||
COPY --chown=unftp:unftp --chmod=755 ./x86_64-unknown-linux-musl/unftp_x86_64-unknown-linux-musl /unftp/unftp | ||
|
||
VOLUME /srv | ||
WORKDIR /unftp | ||
USER unftp | ||
CMD ["scuttle", "/unftp/unftp", "-vv"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
FROM rust:1.70.0-slim AS builder | ||
|
||
FROM alpine:latest | ||
|
||
# we could also RUN 'apk add ca-certificates', but we prefer to be consistent with the -minimal image | ||
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt | ||
|
||
# run as user for security | ||
RUN mkdir /unftp && mkdir -p /srv | ||
RUN addgroup -g 1010 unftp \ | ||
&& adduser -D -s /bin/sh -u 1010 -G unftp unftp \ | ||
&& chown -R unftp:unftp /unftp /srv | ||
COPY --chown=unftp:unftp --chmod=755 ./x86_64-unknown-linux-musl/unftp_x86_64-unknown-linux-musl /unftp/unftp | ||
|
||
VOLUME /srv | ||
WORKDIR /unftp | ||
USER unftp | ||
CMD ["/unftp/unftp", "-vv"] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
FROM rust:1.70.0-slim AS builder | ||
|
||
FROM scratch | ||
|
||
COPY --from=builder /etc/ssl/certs/ca-certificates.crt /etc/ssl/certs/ca-certificates.crt | ||
COPY --chown=1010:1010 --from=builder /srv /srv | ||
COPY --chown=1010:1010 ./x86_64-unknown-linux-musl/unftp_x86_64-unknown-linux-musl /unftp | ||
|
||
VOLUME /srv | ||
USER 1010 | ||
CMD ["/unftp", "-vv"] |