forked from wormhole-foundation/wormhole
-
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.
Implement wasm client for the bridge core
Change-Id: I7931eef27d8b10eaeec00833ab3dc28a57257cdf
- Loading branch information
1 parent
d33738e
commit f9eb8a2
Showing
18 changed files
with
1,921 additions
and
221 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 |
---|---|---|
@@ -0,0 +1,15 @@ | ||
#!/usr/bin/env bash | ||
# Regenerate bridge_ui/rust_modules | ||
set -euo pipefail | ||
|
||
( | ||
cd solana | ||
mkdir -p ../bridge_ui/rust_modules/core | ||
docker build -t localhost/certusone/wormhole-wasmpack:latest -f Dockerfile.wasm . | ||
docker run --rm -it --workdir /usr/src/bridge/bridge/program \ | ||
-v $(pwd)/../bridge_ui/rust_modules/core:/usr/src/bridge/bridge/program/pkg \ | ||
-e EMITTER_ADDRESS=11111111111111111111111111111115 \ | ||
localhost/certusone/wormhole-wasmpack:latest \ | ||
/usr/local/cargo/bin/wasm-pack build --target nodejs -- --features no-entrypoint | ||
cp $(pwd)/../bridge_ui/rust_modules/core/. $(pwd)/../clients/solana/pkg/ -R | ||
) |
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,17 @@ | ||
# syntax=docker.io/docker/dockerfile:experimental@sha256:de85b2f3a3e8a2f7fe48e8e84a65f6fdd5cd5183afa6412fff9caa6871649c44 | ||
FROM docker.io/library/rust:1.49@sha256:a50165ea96983c21832578afb1c8c028674c965bc1ed43b607871b1f362e06a5 | ||
|
||
RUN apt-get update && apt-get install -y libssl-dev libudev-dev pkg-config zlib1g-dev llvm clang | ||
RUN rustup component add rustfmt | ||
RUN rustup default nightly | ||
|
||
WORKDIR /usr/src/bridge | ||
|
||
RUN cargo install wasm-pack | ||
|
||
ENV RUST_LOG="solana_runtime::system_instruction_processor=trace,solana_runtime::message_processor=trace,solana_bpf_loader=debug,solana_rbpf=debug" | ||
ENV EMITTER_ADDRESS="11111111111111111111111111111115" | ||
|
||
COPY bridge bridge | ||
COPY modules modules | ||
COPY solitaire solitaire |
Oops, something went wrong.