chainsaw massacre
This commit is contained in:
@@ -1,28 +0,0 @@
|
||||
# Build Fantom in a stock Go builder container
|
||||
FROM golang:1.19-alpine as builder
|
||||
|
||||
# Install packages we need
|
||||
RUN apk add --no-cache make gcc musl-dev linux-headers git
|
||||
|
||||
# Make a folder to work in
|
||||
RUN mkdir /fantom
|
||||
|
||||
# Grab VERSION from Build Args
|
||||
ARG VERSION
|
||||
|
||||
# Clone the repo to that folder
|
||||
RUN git clone --branch ${VERSION} https://github.com/Fantom-foundation/go-opera.git /fantom
|
||||
|
||||
# Build Fantom
|
||||
RUN cd /fantom && make
|
||||
|
||||
# Pull Fantom into a second stage deploy alpine container
|
||||
FROM alpine:latest
|
||||
|
||||
RUN apk add --no-cache ca-certificates wget tzdata
|
||||
COPY --from=builder /fantom/build/opera /usr/local/bin/
|
||||
|
||||
# Set entrypoint
|
||||
COPY ./scripts/entrypoint.sh /usr/local/bin/entrypoint.sh
|
||||
RUN chmod u+x /usr/local/bin/entrypoint.sh
|
||||
ENTRYPOINT [ "/usr/local/bin/entrypoint.sh" ]
|
||||
@@ -1,28 +0,0 @@
|
||||
# Build Fantom in a stock Go builder container
|
||||
FROM golang:1.19-alpine as builder
|
||||
|
||||
# Install packages we need
|
||||
RUN apk add --no-cache make gcc musl-dev linux-headers git
|
||||
|
||||
# Make a folder to work in
|
||||
RUN mkdir /fantom
|
||||
|
||||
# Grab VERSION from Build Args
|
||||
ARG VERSION
|
||||
|
||||
# Clone the repo to that folder
|
||||
RUN git clone --branch ${VERSION} https://github.com/Fantom-foundation/go-opera.git /fantom
|
||||
|
||||
# Build Fantom
|
||||
RUN cd /fantom && make
|
||||
|
||||
# Pull Fantom into a second stage deploy alpine container
|
||||
FROM alpine:latest
|
||||
|
||||
RUN apk add --no-cache ca-certificates wget tzdata openssl xxd
|
||||
COPY --from=builder /fantom/build/opera /usr/local/bin/
|
||||
|
||||
# Set entrypoint
|
||||
COPY ./scripts/entrypoint-fullnode.sh /usr/local/bin/entrypoint.sh
|
||||
RUN chmod u+x /usr/local/bin/entrypoint.sh
|
||||
ENTRYPOINT [ "/usr/local/bin/entrypoint.sh" ]
|
||||
@@ -1,28 +0,0 @@
|
||||
# Build Fantom in a stock Go builder container
|
||||
FROM golang:1.19-alpine as builder
|
||||
|
||||
# Install packages we need
|
||||
RUN apk add --no-cache make gcc musl-dev linux-headers git
|
||||
|
||||
# Make a folder to work in
|
||||
RUN mkdir /fantom
|
||||
|
||||
# Grab VERSION from Build Args
|
||||
ARG VERSION
|
||||
|
||||
# Clone the repo to that folder
|
||||
RUN git clone --branch ${VERSION} https://github.com/Fantom-foundation/go-opera.git /fantom
|
||||
|
||||
# Build Fantom
|
||||
RUN cd /fantom && make
|
||||
|
||||
# Pull Fantom into a second stage deploy alpine container
|
||||
FROM alpine:latest
|
||||
|
||||
RUN apk add --no-cache ca-certificates wget tzdata
|
||||
COPY --from=builder /fantom/build/opera /usr/local/bin/
|
||||
|
||||
# Set entrypoint
|
||||
COPY ./scripts/entrypoint-testnet-fullnode.sh /usr/local/bin/entrypoint.sh
|
||||
RUN chmod u+x /usr/local/bin/entrypoint.sh
|
||||
ENTRYPOINT [ "/usr/local/bin/entrypoint.sh" ]
|
||||
@@ -1,30 +0,0 @@
|
||||
# Build Fantom in a stock Go builder container
|
||||
FROM golang:1.19-alpine as builder
|
||||
|
||||
# Install packages we need
|
||||
RUN apk add --no-cache make gcc musl-dev linux-headers git
|
||||
|
||||
# Make a folder to work in
|
||||
RUN mkdir /fantom
|
||||
|
||||
# Grab VERSION from Build Args
|
||||
ARG VERSION
|
||||
ARG REPO
|
||||
|
||||
# Clone the repo to that folder
|
||||
RUN git clone --branch ${VERSION} ${REPO:-https://github.com/Fantom-foundation/go-opera.git} /fantom
|
||||
|
||||
# Build Fantom
|
||||
RUN cd /fantom && make
|
||||
|
||||
# Pull Fantom into a second stage deploy alpine container
|
||||
FROM alpine:latest
|
||||
|
||||
RUN apk add --no-cache ca-certificates wget tzdata
|
||||
COPY --from=builder /fantom/build/opera /usr/local/bin/
|
||||
|
||||
VOLUME /datadir
|
||||
|
||||
COPY ./scripts/entrypoint.opera.sh /usr/local/bin/entrypoint.sh
|
||||
RUN chmod u+x /usr/local/bin/entrypoint.sh
|
||||
ENTRYPOINT [ "/usr/local/bin/entrypoint.sh" ]
|
||||
@@ -1,26 +0,0 @@
|
||||
FROM golang:1.22 as builder
|
||||
|
||||
ARG VERSION
|
||||
ARG REPO
|
||||
|
||||
RUN apt-get update && apt-get install -y git musl-dev make
|
||||
|
||||
RUN cd /go && git clone ${REPO:-https://github.com/Fantom-foundation/sonic.git} sonic && cd sonic && git fetch --tags && git checkout -b ${VERSION} tags/${VERSION}
|
||||
|
||||
WORKDIR /go/sonic
|
||||
|
||||
ARG GOPROXY
|
||||
RUN go mod download
|
||||
RUN make all
|
||||
|
||||
FROM golang:1.22
|
||||
|
||||
COPY --from=builder /go/sonic/build/sonicd /usr/local/bin/
|
||||
COPY --from=builder /go/sonic/build/sonictool /usr/local/bin/
|
||||
|
||||
COPY ./scripts/entrypoint.sonic.sh /usr/local/bin/entrypoint.sh
|
||||
|
||||
VOLUME /var/sonic
|
||||
|
||||
RUN chmod u+x /usr/local/bin/entrypoint.sh
|
||||
ENTRYPOINT [ "/usr/local/bin/entrypoint.sh" ]
|
||||
@@ -1,52 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# exit script on any error
|
||||
set -e
|
||||
|
||||
# Set fantom Home Directory
|
||||
FANTOM_HOME=/datadir
|
||||
|
||||
if [ ! -f "$FANTOM_HOME/mainnet-171200-no-history.g" ];
|
||||
then
|
||||
cd $FANTOM_HOME
|
||||
echo "downloading launch genesis file"
|
||||
wget --quiet https://files.fantom.network/mainnet-171200-no-history.g
|
||||
fi
|
||||
|
||||
# uncomment the next line and do docker-compose build in case you have to try to fix the db after unclean shutdown etc.
|
||||
# opera --db.preset pbl-1 --datadir=$FANTOM_HOME db heal --experimental
|
||||
|
||||
# Generate nodekey only if it doesn't exist
|
||||
if [ ! -f /config/nodekey ]; then
|
||||
echo "Generating new Geth node key..."
|
||||
openssl rand 32 | xxd -p -c 32 | tr -d '\n' > /config/nodekey
|
||||
echo "Node key generated: $(cat /config/nodekey)"
|
||||
else
|
||||
echo "Node key already exists, skipping generation."
|
||||
fi
|
||||
|
||||
exec opera \
|
||||
--genesis=$FANTOM_HOME/mainnet-171200-no-history.g \
|
||||
--port=19921 \
|
||||
--maxpeers=200 \
|
||||
--datadir=$FANTOM_HOME \
|
||||
--http \
|
||||
--http.addr=0.0.0.0 \
|
||||
--http.port=18544 \
|
||||
--http.api=ftm,eth,debug,admin,web3,personal,net,txpool,sfc,trace \
|
||||
--http.corsdomain="*" \
|
||||
--http.vhosts="*" \
|
||||
--nat extip:${IP} \
|
||||
--nodekey=/config/nodekey \
|
||||
--ws \
|
||||
--ws.addr=0.0.0.0 \
|
||||
--ws.port=18544 \
|
||||
--ws.api=ftm,eth,debug,admin,web3,personal,net,txpool,sfc,trace \
|
||||
--ws.origins="*" \
|
||||
--nousb \
|
||||
--rpc.gascap=600000000 \
|
||||
--db.migration.mode reformat \
|
||||
--tracenode \
|
||||
--db.preset pbl-1 \
|
||||
--cache=${CACHE_SIZE:-16000} \
|
||||
--syncmode=snap
|
||||
@@ -1,40 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# exit script on any error
|
||||
set -e
|
||||
|
||||
# Set fantom Home Directory
|
||||
FANTOM_HOME=/datadir
|
||||
|
||||
if [ ! -f "$FANTOM_HOME/testnet-16200-pruned-mpt.g" ];
|
||||
then
|
||||
cd $FANTOM_HOME
|
||||
echo "downloading launch genesis file"
|
||||
wget --quiet https://files.fantom.network/testnet-16200-pruned-mpt.g
|
||||
fi
|
||||
|
||||
# uncomment the next line and do docker-compose build in case you have to try to fix the db after unclean shutdown etc.
|
||||
# opera --db.preset pbl-1 --datadir=$FANTOM_HOME db heal --experimental
|
||||
|
||||
exec opera \
|
||||
--genesis=$FANTOM_HOME/testnet-16200-pruned-mpt.g \
|
||||
--port=44629 \
|
||||
--maxpeers=200 \
|
||||
--datadir=$FANTOM_HOME \
|
||||
--http \
|
||||
--http.addr=0.0.0.0 \
|
||||
--http.port=18544 \
|
||||
--http.api=ftm,eth,debug,admin,web3,personal,net,txpool \
|
||||
--http.corsdomain="*" \
|
||||
--http.vhosts="*" \
|
||||
--ws \
|
||||
--ws.addr=0.0.0.0 \
|
||||
--ws.port=18544 \
|
||||
--ws.api=ftm,eth,debug,admin,web3,personal,net,txpool \
|
||||
--ws.origins="*" \
|
||||
--nat=extip:${IP} \
|
||||
--nousb \
|
||||
--db.migration.mode reformat \
|
||||
--db.preset pbl-1 \
|
||||
--cache=${CACHE_SIZE:-16000} \
|
||||
--syncmode=snap
|
||||
@@ -1,46 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
# exit script on any error
|
||||
set -e
|
||||
|
||||
# Set fantom Home Directory
|
||||
FANTOM_HOME=/datadir
|
||||
|
||||
if [ -n "${SNAPSHOT_URL}" ] && [ ! -f "${FANTOM_HOME}/bootstrapped" ];
|
||||
then
|
||||
echo "downloading snapshot from ${SNAPSHOT_URL}"
|
||||
wget --tries=0 -O - "${SNAPSHOT_URL}" | tar -xz --strip-components=1 -C ${FANTOM_HOME}/ && touch ${FANTOM_HOME}/bootstrapped
|
||||
fi
|
||||
|
||||
if [ ! -f "$FANTOM_HOME/mainnet-5577-full-mpt.g" ];
|
||||
then
|
||||
cd $FANTOM_HOME
|
||||
echo "downloading launch genesis file"
|
||||
wget --quiet https://download.fantom.network/opera/mainnet/mainnet-5577-full-mpt.g
|
||||
fi
|
||||
|
||||
# uncomment the next line and do docker-compose build in case you have to try to fix the db after unclean shutdown etc.
|
||||
# opera --db.preset pbl-1 --datadir=$FANTOM_HOME db heal --experimental
|
||||
|
||||
exec opera \
|
||||
--genesis=$FANTOM_HOME/mainnet-5577-full-mpt.g \
|
||||
--port=5050 \
|
||||
--maxpeers=200 \
|
||||
--datadir=$FANTOM_HOME \
|
||||
--http \
|
||||
--bootnodes=${BOOTNODES:-enode://94dfec3eb6e50187d22d12f7dd965169bab5a63022934ef0b3b82a819574e0940b5bcb471f62360f1b58cf61a89e634bd14ae7c2e29ce48088890f4a7aff44fe@75.98.207.227:5050,enode://7fb3f43273f4dfeb19c3129c6ed999e14246d2f219ff284d0ef87417cd9514c6d542abc988a654b4a77005ea896c5b4e4ca0d40f97f3bf9ee37be33cc749835f@209.172.40.68:5050,enode://27a80a1db08a40636415d4ff9bb272882b6a6f97a9a5d596006de843f35cbbc679e5252d89d3de05bd74c36cf9f5ce2446dd66cdd5dc7e942a585eb4add61124@37.27.70.18:5050,enode://946fef1538abd165f8bd2ae1c290e7689ff5e209ab6c085eaced9b91e93684b1efe05f79a9a9b460504c450065baaeda5ecb72c03f8adf7e7a559042ce4950da@136.243.252.124:5078,enode://cf762e3a68f8a96676d6383cd3286b85ef7454ef37bb39283efe00d3d573d88f05db3daab7c35a4d3ba9edd9d089e359a25de5beeb24f79f6c1b9e5341958cee@15.235.54.211:5050} \
|
||||
--http.addr=0.0.0.0 \
|
||||
--http.port=18544 \
|
||||
--http.api=ftm,eth,debug,admin,web3,personal,net,txpool,sfc,trace \
|
||||
--http.corsdomain="*" \
|
||||
--http.vhosts="*" \
|
||||
--ws \
|
||||
--ws.addr=0.0.0.0 \
|
||||
--ws.port=18544 \
|
||||
--ws.api=ftm,eth,debug,admin,web3,personal,net,txpool,sfc \
|
||||
--ws.origins="*" \
|
||||
--nousb \
|
||||
--db.migration.mode reformat \
|
||||
--db.preset pbl-1 \
|
||||
--cache=${CACHE_SIZE:-16000} \
|
||||
--tracenode
|
||||
Reference in New Issue
Block a user