mirror of
https://github.com/lightninglabs/lightning-terminal.git
synced 2026-08-13 12:33:36 +02:00
dev.Dockerfile: allow forcing frdrpc repo and version
faraday/frdrpc is a separate Go module with independent versioning, so overriding faraday alone can leave frdrpc pinned to the go.mod version and cause a build mismatch when changes span both modules. Add FRDRPC_REPO and FRDRPC_VERSION build args that mirror the faraday block, matching how taproot-assets and taprpc are handled. Signed-off-by: 0xfandom <kashyapshivank01@gmail.com>
This commit is contained in:
parent
331f46cca8
commit
33afe40b0c
1 changed files with 22 additions and 10 deletions
|
|
@ -30,22 +30,23 @@ COPY --from=nodejsbuilder /go/src/github.com/lightninglabs/lightning-terminal /g
|
|||
# queries required to connect to linked containers succeed.
|
||||
ENV GODEBUG netdns=cgo
|
||||
|
||||
# Allow forcing a specific lnd, taproot-assets, taprpc, loop, and/or faraday
|
||||
# repo so that commits referenced by LND_VERSION, TAPROOT_ASSETS_VERSION,
|
||||
# TAPRPC_VERSION, LOOP_VERSION, and FARADAY_VERSION don't have to exist in the
|
||||
# default repository. If any of these build arguments are not defined, the
|
||||
# build continues using the default repository for that module. NOTE: If these
|
||||
# arguments ARE defined then the corresponding `_VERSION` argument MUST also be
|
||||
# defined, otherwise the build continues using the default repository defined
|
||||
# for that module.
|
||||
# Allow forcing a specific lnd, taproot-assets, taprpc, loop, faraday, and/or
|
||||
# frdrpc repo so that commits referenced by LND_VERSION,
|
||||
# TAPROOT_ASSETS_VERSION, TAPRPC_VERSION, LOOP_VERSION, FARADAY_VERSION, and
|
||||
# FRDRPC_VERSION don't have to exist in the default repository. If any of these
|
||||
# build arguments are not defined, the build continues using the default
|
||||
# repository for that module. NOTE: If these arguments ARE defined then the
|
||||
# corresponding `_VERSION` argument MUST also be defined, otherwise the build
|
||||
# continues using the default repository defined for that module.
|
||||
ARG LND_REPO
|
||||
ARG TAPROOT_ASSETS_REPO
|
||||
ARG TAPRPC_REPO
|
||||
ARG LOOP_REPO
|
||||
ARG FARADAY_REPO
|
||||
ARG FRDRPC_REPO
|
||||
|
||||
# Allow forcing a specific lnd, taproot-assets, taprpc, loop, and/or faraday
|
||||
# version through a build argument.
|
||||
# Allow forcing a specific lnd, taproot-assets, taprpc, loop, faraday, and/or
|
||||
# frdrpc version through a build argument.
|
||||
# Please see https://go.dev/ref/mod#version-queries for the types of
|
||||
# queries that can be used to define a version.
|
||||
# If any of these build arguments are not defined then build uses the version
|
||||
|
|
@ -62,6 +63,7 @@ ARG TAPROOT_ASSETS_VERSION
|
|||
ARG TAPRPC_VERSION
|
||||
ARG LOOP_VERSION
|
||||
ARG FARADAY_VERSION
|
||||
ARG FRDRPC_VERSION
|
||||
|
||||
# Need to restate this since running in a new container from above.
|
||||
ARG NO_UI
|
||||
|
|
@ -131,6 +133,16 @@ RUN --mount=type=cache,target=/go/pkg/mod \
|
|||
fi \
|
||||
&& go mod tidy; \
|
||||
fi \
|
||||
# If a custom frdrpc version is supplied, force it now.
|
||||
&& if [ -n "$FRDRPC_VERSION" ]; then \
|
||||
# If a custom frdrpc repo is supplied, force it now.
|
||||
if [ -n "$FRDRPC_REPO" ]; then \
|
||||
go mod edit -replace=github.com/lightninglabs/faraday/frdrpc=$FRDRPC_REPO@$FRDRPC_VERSION; \
|
||||
else \
|
||||
go get -v github.com/lightninglabs/faraday/frdrpc@$FRDRPC_VERSION; \
|
||||
fi \
|
||||
&& go mod tidy; \
|
||||
fi \
|
||||
&& if [ "$NO_UI" -eq "1" ]; then \
|
||||
make go-install-noui \
|
||||
&& make go-install-cli-noui; \
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue