diff --git a/.github/workflows/e2e.yml b/.github/workflows/e2e.yml index b8be576..d11e562 100644 --- a/.github/workflows/e2e.yml +++ b/.github/workflows/e2e.yml @@ -3,10 +3,25 @@ name: "e2e" on: pull_request: paths-ignore: - - "!**.md" + - "**.md" + - ".github/**" + - "!.github/workflows/e2e.yml" + - "!.github/workflows/snapshot.yml" + - "!.github/workflows/build.yml" + types: + - "labeled" + - "synchronize" + - "opened" + - "reopened" push: branches: - "master" + paths-ignore: + - "**.md" + - ".github/**" + - "!.github/workflows/e2e.yml" + - "!.github/workflows/snapshot.yml" + - "!.github/workflows/build.yml" concurrency: group: "${{ github.workflow }}-${{ github.ref }}" @@ -24,19 +39,6 @@ jobs: name: "sqlite-wasm" uses: fluencelabs/sqlite-wasm-connector/.github/workflows/snapshot.yml@master - registry: - needs: - - snapshot - uses: fluencelabs/registry/.github/workflows/tests.yml@main - with: - cargo-dependencies: | - [ - { - "package": "marine-sqlite-connector", - "version": "=${{ needs.snapshot.outputs.version }}", - "registry": "fluence" - } - ] spell: needs: - snapshot @@ -55,9 +57,8 @@ jobs: needs: - spell - uses: fluencelabs/rust-peer/.github/workflows/snapshot.yml@master + uses: fluencelabs/rust-peer/.github/workflows/build.yml@master with: - image-name: "docker.fluence.dev/sqlite-wasm-connector" cargo-dependencies: | [ { @@ -72,10 +73,37 @@ jobs: } ] + rust-peer-snapshot: + name: "rust-peer" + needs: + - rust-peer + + uses: fluencelabs/rust-peer/.github/workflows/container.yml@master + with: + image-name: "docker.fluence.dev/sqlite-wasm-connector" + flavour: "minimal" + rust-peer-sha: "${{ needs.rust-peer.outputs.rust-peer-sha }}" + spell-aqua-tests: name: "spell" needs: - - rust-peer + - rust-peer-snapshot uses: fluencelabs/spell/.github/workflows/tests.yml@main with: - rust-peer-image: "${{ needs.rust-peer.outputs.rust-peer-image }}" + rust-peer-image: "${{ needs.rust-peer-snapshot.outputs.rust-peer-image }}" + + registry: + needs: + - snapshot + - rust-peer-snapshot + uses: fluencelabs/registry/.github/workflows/tests.yml@main + with: + rust-peer-image: "${{ needs.rust-peer-snapshot.outputs.rust-peer-image }}" + cargo-dependencies: | + [ + { + "package": "marine-sqlite-connector", + "version": "=${{ needs.snapshot.outputs.version }}", + "registry": "fluence" + } + ] diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..db5c88e --- /dev/null +++ b/Dockerfile @@ -0,0 +1,17 @@ +FROM ubuntu:20.04 + +RUN apt update \ + && DEBIAN_FRONTEND=noninteractive TZ=Etc/UTC apt-get -y install tzdata \ + && apt install -y ca-certificates \ + curl \ + git \ + make \ + pkg-config \ + libtinfo6 \ + cargo + +RUN cargo install marine + +VOLUME /code +WORKDIR /code +ENTRYPOINT /code/entrypoint.sh diff --git a/docker-compose.yml b/docker-compose.yml new file mode 100644 index 0000000..93ca78b --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1,8 @@ +version: '3' +services: + sqlite3: + build: + context: . + container_name: sqlite3_builder + volumes: + - ./:/code diff --git a/entrypoint.sh b/entrypoint.sh new file mode 100755 index 0000000..ef5fb33 --- /dev/null +++ b/entrypoint.sh @@ -0,0 +1,4 @@ +export PATH="${PATH}:/root/.cargo/bin" +curl -L https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-15/wasi-sdk-15.0-linux.tar.gz | tar xz -C . +mv wasi-sdk-* wasi-sdk +make