figure out why these changes were needed

This commit is contained in:
Jeffrey Picard 2021-11-11 08:47:53 +00:00
parent 4e9eae447f
commit 7daf79ef8f
2 changed files with 8 additions and 10 deletions

View file

@ -14,12 +14,9 @@
# 9246 Mainnet Bitcoin peer-to-peer port # 9246 Mainnet Bitcoin peer-to-peer port
# 9245 Mainet RPC port # 9245 Mainet RPC port
ARG ARCH=amd64 FROM golang AS build-container
FROM golang:1.17-buster AS build-container # ENV GO111MODULE=on
ARG ARCH
ENV GO111MODULE=on
ADD . /app ADD . /app
WORKDIR /app WORKDIR /app
@ -27,14 +24,15 @@ RUN set -ex \
&& if [ "${ARCH}" = "amd64" ]; then export GOARCH=amd64; fi \ && if [ "${ARCH}" = "amd64" ]; then export GOARCH=amd64; fi \
&& if [ "${ARCH}" = "arm64v8" ]; then export GOARCH=arm64; fi \ && if [ "${ARCH}" = "arm64v8" ]; then export GOARCH=arm64; fi \
&& echo "Compiling for $GOARCH" \ && echo "Compiling for $GOARCH" \
&& go install -v . ./cmd/... && CGO_ENABLED=0 go build .
FROM $ARCH/alpine:3.14 FROM debian:11-slim
COPY --from=build-container /go/bin /bin COPY --from=build-container /app/lbcd /
COPY --from=build-container /app/run.sh /
VOLUME ["/root/.lbcd"] VOLUME ["/root/.lbcd"]
EXPOSE 9245 9246 EXPOSE 9245 9246
ENTRYPOINT ["/app/run.sh"] ENTRYPOINT ["/run.sh"]

2
run.sh
View file

@ -1,2 +1,2 @@
#!/bin/bash #!/bin/bash
lbcd --txindex --notls --rpcuser=lbry --rpcpass=lbry --rpclisten=$LISTEN_ADDR:9245 /lbcd --txindex --notls --rpcuser=lbry --rpcpass=lbry --rpclisten=