File tree Expand file tree Collapse file tree 2 files changed +14
-4
lines changed Expand file tree Collapse file tree 2 files changed +14
-4
lines changed Original file line number Diff line number Diff line change 1
1
# IDE configs
2
2
.vscode
3
- .idea
3
+ .idea
4
+
5
+ # Compiled output
6
+ firefly-tezosconnect
Original file line number Diff line number Diff line change @@ -2,8 +2,12 @@ FROM golang:1.21-alpine3.19 AS builder
2
2
RUN apk add make
3
3
ARG BUILD_VERSION
4
4
ENV BUILD_VERSION=${BUILD_VERSION}
5
- ADD . /tezosconnect
5
+ ADD --chown=1001:0 . /tezosconnect
6
6
WORKDIR /tezosconnect
7
+ RUN mkdir /.cache \
8
+ && chgrp -R 0 /.cache \
9
+ && chmod -R g+rwX /.cache
10
+ USER 1001
7
11
RUN make
8
12
9
13
# Copy the migrations from FFTM down into our local migrations directory
@@ -12,13 +16,16 @@ RUN DB_MIGRATIONS_DIR=$(go list -f '{{.Dir}}' github.com/hyperledger/firefly-tra
12
16
13
17
FROM debian:buster-slim
14
18
WORKDIR /tezosconnect
19
+ RUN chgrp -R 0 /tezosconnect \
20
+ && chmod -R g+rwX /tezosconnect
15
21
RUN apt update -y \
16
22
&& apt install -y curl jq \
17
23
&& rm -rf /var/lib/apt/lists/* \
18
24
&& curl -sL "https://github.com/golang-migrate/migrate/releases/download/$(curl -sL https://api.github.com/repos/golang-migrate/migrate/releases/latest | jq -r '.name')/migrate.linux-amd64.tar.gz" | tar xz \
19
25
&& chmod +x ./migrate \
20
26
&& mv ./migrate /usr/bin/migrate
21
- COPY --from=builder /tezosconnect/firefly-tezosconnect /usr/bin/tezosconnect
22
- COPY --from=builder /tezosconnect/db/ /tezosconnect/db/
27
+ COPY --from=builder --chown=1001:0 /tezosconnect/firefly-tezosconnect /usr/bin/tezosconnect
28
+ COPY --from=builder --chown=1001:0 /tezosconnect/db/ /tezosconnect/db/
29
+ USER 1001
23
30
24
31
ENTRYPOINT [ "/usr/bin/tezosconnect" ]
You can’t perform that action at this time.
0 commit comments