forked from sei-protocol/sei-chain
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Temporary almsot emtpy tracer version
- Loading branch information
Showing
12 changed files
with
3,087 additions
and
41 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
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 |
---|---|---|
|
@@ -7,6 +7,9 @@ release/ | |
build/ | ||
cache/ | ||
|
||
/seid-* | ||
/libwasmvm.x86_64.so | ||
|
||
# Local .terraform directories | ||
**/.terraform | ||
|
||
|
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 |
---|---|---|
@@ -0,0 +1,63 @@ | ||
FROM ubuntu:22.04 AS base | ||
|
||
WORKDIR /app | ||
|
||
RUN apt-get update && apt-get install -y apt-transport-https ca-certificates curl gnupg tar jq vim wget | ||
|
||
RUN curl -LO https://github.com/chmln/sd/releases/download/v1.0.0/sd-v1.0.0-x86_64-unknown-linux-gnu.tar.gz \ | ||
&& tar -xzf sd-v1.0.0-x86_64-unknown-linux-gnu.tar.gz \ | ||
&& cp sd-v1.0.0-x86_64-unknown-linux-gnu/sd /usr/local/bin/sd \ | ||
&& rm -rf sd-v1.0.0-x86_64-unknown-linux-gnu sd-v1.0.0-x86_64-unknown-linux-gnu.tar.gz | ||
|
||
ENV PATH="/app:${PATH}" | ||
|
||
FROM base AS fireeth_download | ||
|
||
ARG FIREETH="v2.6.7" | ||
|
||
# Download and extract the binary file | ||
RUN curl -LO https://github.com/streamingfast/firehose-ethereum/releases/download/${FIREETH}/firehose-ethereum_linux_x86_64.tar.gz \ | ||
&& tar -xzf firehose-ethereum_linux_x86_64.tar.gz \ | ||
&& rm firehose-ethereum_linux_x86_64.tar.gz | ||
|
||
FROM golang:1.22-alpine AS libwasmvm_download | ||
|
||
COPY ./go.mod /work/go.mod | ||
COPY ./go.sum /work/go.sum | ||
|
||
# FIXME: Handle multi-arch build, for now we have hard-coded the x86_64 part, but we should be able to build for arm64 as well | ||
RUN apk add --no-cache wget && cd /work; \ | ||
export ARCH=$(uname -m); \ | ||
export WASM_VERSION="$(go list -m all | grep github.com/CosmWasm/wasmvm | awk '{print $2}')"; \ | ||
wget -O "/lib/libwasmvm.x86_64.${WASM_VERSION}.so" https://github.com/CosmWasm/wasmvm/releases/download/${WASM_VERSION}/libwasmvm.x86_64.so && \ | ||
printf "${WASM_VERSION}" > /lib/libwasmvm.x86_64.so.version | ||
|
||
FROM base AS cosmovisor_download | ||
|
||
ARG COSMOVISOR="v1.5.0" | ||
|
||
# Download and extract the binary file | ||
RUN curl -LO https://github.com/cosmos/cosmos-sdk/releases/download/cosmovisor%2F${COSMOVISOR}/cosmovisor-${COSMOVISOR}-linux-amd64.tar.gz \ | ||
&& tar -xzf cosmovisor-${COSMOVISOR}-linux-amd64.tar.gz \ | ||
&& rm cosmovisor-${COSMOVISOR}-linux-amd64.tar.gz | ||
|
||
FROM base AS base_with_gcloud | ||
|
||
RUN echo "deb [signed-by=/usr/share/keyrings/cloud.google.gpg] https://packages.cloud.google.com/apt cloud-sdk main" | tee -a /etc/apt/sources.list.d/google-cloud-sdk.list \ | ||
&& curl https://packages.cloud.google.com/apt/doc/apt-key.gpg | gpg --dearmor -o /usr/share/keyrings/cloud.google.gpg \ | ||
&& apt-get update -y \ | ||
&& apt-get install google-cloud-sdk -y | ||
|
||
FROM base_with_gcloud | ||
|
||
ARG SEID_BIN="seid" | ||
|
||
COPY --from=fireeth_download /app/fireeth /app/fireeth | ||
COPY --from=libwasmvm_download /lib/libwasmvm.x86_64.*.so /lib/ | ||
COPY --from=libwasmvm_download /lib/libwasmvm.x86_64.so.version /lib/ | ||
|
||
COPY ./${SEID_BIN} /app/seid | ||
|
||
RUN chmod +x /app/fireeth && \ | ||
export WASM_VERSION=$(cat /lib/libwasmvm.x86_64.so.version) && \ | ||
ln -s /lib/libwasmvm.x86_64.${WASM_VERSION}.so /lib/libwasmvm.x86_64.so |
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.