Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
multi: add flap count and last flap time to listpeers
- Loading branch information
Showing
7 changed files
with
963 additions
and
759 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,43 +1,36 @@ | ||
FROM golang:1.14.5-alpine as builder | ||
FROM golang:1.13-alpine as builder | ||
|
||
LABEL maintainer="Olaoluwa Osuntokun <laolu@lightning.engineering>" | ||
|
||
# Force Go to use the cgo based DNS resolver. This is required to ensure DNS | ||
# queries required to connect to linked containers succeed. | ||
ENV GODEBUG netdns=cgo | ||
|
||
# Pass a tag, branch or a commit using build-arg. This allows a docker | ||
# image to be built from a specified Git state. The default image | ||
# will use the Git tip of master by default. | ||
ARG checkout="master" | ||
|
||
# Install dependencies and build the binaries. | ||
# Install dependencies and install/build lnd. | ||
RUN apk add --no-cache --update alpine-sdk \ | ||
git \ | ||
make \ | ||
gcc \ | ||
&& git clone https://github.com/lightningnetwork/lnd /go/src/github.com/lightningnetwork/lnd \ | ||
&& cd /go/src/github.com/lightningnetwork/lnd \ | ||
&& git checkout $checkout \ | ||
make | ||
|
||
# Copy in the local repository to build from. | ||
COPY . /go/src/github.com/lightningnetwork/lnd | ||
|
||
RUN cd /go/src/github.com/lightningnetwork/lnd \ | ||
&& make \ | ||
&& make install tags="signrpc walletrpc chainrpc invoicesrpc" | ||
|
||
# Start a new, final image. | ||
# Start a new, final image to reduce size. | ||
FROM alpine as final | ||
|
||
# Define a root volume for data persistence. | ||
VOLUME /root/.lnd | ||
|
||
# Add bash, jq and ca-certs, for quality of life and SSL-related reasons. | ||
RUN apk --no-cache add \ | ||
bash \ | ||
jq \ | ||
ca-certificates | ||
# Expose lnd ports (server, rpc). | ||
EXPOSE 9735 10009 | ||
|
||
# Copy the binaries from the builder image. | ||
# Copy the binaries and entrypoint from the builder image. | ||
COPY --from=builder /go/bin/lncli /bin/ | ||
COPY --from=builder /go/bin/lnd /bin/ | ||
|
||
# Expose lnd ports (p2p, rpc). | ||
EXPOSE 9735 10009 | ||
# Add bash. | ||
RUN apk add --no-cache \ | ||
bash | ||
|
||
# Specify the start command and entrypoint as the lnd daemon. | ||
ENTRYPOINT ["lnd"] |
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
Oops, something went wrong.