-
Notifications
You must be signed in to change notification settings - Fork 606
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
create image and makefile steps to initialize chain state
- Loading branch information
Showing
3 changed files
with
51 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,23 @@ | ||
# syntax=docker/dockerfile:1 | ||
|
||
## Build Image | ||
FROM golang:1.18-bullseye as build | ||
|
||
WORKDIR /osmosis | ||
COPY . /osmosis | ||
|
||
# From https://github.com/CosmWasm/wasmd/blob/master/Dockerfile | ||
# For more details see https://github.com/CosmWasm/wasmvm#builds-of-libwasmvm | ||
ADD https://github.com/CosmWasm/wasmvm/releases/download/v1.0.0-beta7/libwasmvm_muslc.a /lib/libwasmvm_muslc.a | ||
RUN sha256sum /lib/libwasmvm_muslc.a | grep d0152067a5609bfdfb3f0d5d6c0f2760f79d5f2cd7fd8513cafa9932d22eb350 | ||
RUN BUILD_TAGS=muslc make build-e2e-upgrade | ||
|
||
## Deploy image | ||
FROM ubuntu | ||
|
||
COPY --from=build /osmosis/build/upgrade /bin/upgrade | ||
|
||
ENV HOME /osmosis | ||
WORKDIR $HOME | ||
|
||
CMD [ "upgrade" ] |
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,21 @@ | ||
package main | ||
|
||
import ( | ||
"fmt" | ||
"io/ioutil" | ||
|
||
"github.com/osmosis-labs/osmosis/v7/tests/e2e/chain" | ||
) | ||
|
||
func main() { | ||
tmpDir, err := ioutil.TempDir("", "osmosis-e2e-testnet-") | ||
if err != nil { | ||
panic(err) | ||
} | ||
|
||
chain, err := chain.Init(chain.ChainAID, tmpDir) | ||
if err != nil { | ||
panic(err) | ||
} | ||
fmt.Println(chain) | ||
} |