chore(e2e): Update e2e (#17)

* Update e2e

* Fix

* Bring back docker-compose
This commit is contained in:
Anatolios Laskaris 2023-04-04 19:22:15 +03:00 committed by GitHub
parent ea4bac91b0
commit 8a97f5ca7b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 75 additions and 18 deletions

View File

@ -3,10 +3,25 @@ name: "e2e"
on: on:
pull_request: pull_request:
paths-ignore: paths-ignore:
- "!**.md" - "**.md"
- ".github/**"
- "!.github/workflows/e2e.yml"
- "!.github/workflows/snapshot.yml"
- "!.github/workflows/build.yml"
types:
- "labeled"
- "synchronize"
- "opened"
- "reopened"
push: push:
branches: branches:
- "master" - "master"
paths-ignore:
- "**.md"
- ".github/**"
- "!.github/workflows/e2e.yml"
- "!.github/workflows/snapshot.yml"
- "!.github/workflows/build.yml"
concurrency: concurrency:
group: "${{ github.workflow }}-${{ github.ref }}" group: "${{ github.workflow }}-${{ github.ref }}"
@ -24,19 +39,6 @@ jobs:
name: "sqlite-wasm" name: "sqlite-wasm"
uses: fluencelabs/sqlite-wasm-connector/.github/workflows/snapshot.yml@master 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: spell:
needs: needs:
- snapshot - snapshot
@ -55,9 +57,8 @@ jobs:
needs: needs:
- spell - spell
uses: fluencelabs/rust-peer/.github/workflows/snapshot.yml@master uses: fluencelabs/rust-peer/.github/workflows/build.yml@master
with: with:
image-name: "docker.fluence.dev/sqlite-wasm-connector"
cargo-dependencies: | 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: spell-aqua-tests:
name: "spell" name: "spell"
needs: needs:
- rust-peer - rust-peer-snapshot
uses: fluencelabs/spell/.github/workflows/tests.yml@main uses: fluencelabs/spell/.github/workflows/tests.yml@main
with: 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"
}
]

17
Dockerfile Normal file
View File

@ -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

8
docker-compose.yml Normal file
View File

@ -0,0 +1,8 @@
version: '3'
services:
sqlite3:
build:
context: .
container_name: sqlite3_builder
volumes:
- ./:/code

4
entrypoint.sh Executable file
View File

@ -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