Skip to content

Commit

Permalink
Merge branch 'main' into fix/doc-link
Browse files Browse the repository at this point in the history
  • Loading branch information
YJDoc2 committed Feb 13, 2023
2 parents 2d10a00 + 8bc2f48 commit f2a55e5
Show file tree
Hide file tree
Showing 10 changed files with 124 additions and 165 deletions.
4 changes: 4 additions & 0 deletions .github/scripts/dependency.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/bash

sudo apt-get -y update
sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev
28 changes: 8 additions & 20 deletions .github/workflows/benchmark_execution_time.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,11 @@ jobs:
- name: Checkout to PR branch
uses: actions/checkout@v3

- name: Setup Linux env
run: |
sudo apt -y update
sudo apt install libsystemd-dev librust-libdbus-sys-dev libseccomp-dev
- name: Install requirements
run: ./.github/scripts/dependency.sh

- name: Setting rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
profile: minimal
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]

- name: Building PR branch
run: make youki-release
Expand All @@ -46,17 +40,11 @@ jobs:
with:
ref: main

- name: Setup Linux env
run: |
sudo apt -y update
sudo apt install libsystemd-dev librust-libdbus-sys-dev libseccomp-dev
- name: Install requirements
run: ./.github/scripts/dependency.sh

- name: Setting rust toolchain
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
profile: minimal
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]

- name: Building main branch
run: make youki-release
Expand Down
13 changes: 5 additions & 8 deletions .github/workflows/containerd_integration_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,10 @@ jobs:
timeout-minutes: 15
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: '1.66.0'
override: true
- name: Cache youki
uses: Swatinem/rust-cache@v1
- run: sudo apt-get -y update
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]
- name: Install requirements
run: ./.github/scripts/dependency.sh
- name: Build youki
run: make youki-release
- name: Upload youki binary
Expand All @@ -40,6 +36,7 @@ jobs:
- uses: actions/setup-go@v3
with:
go-version: '1.18.3'
cache: true
- run: sudo apt-get -y update
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev btrfs-progs libbtrfs-dev
- name: Build containerd
Expand Down
15 changes: 4 additions & 11 deletions .github/workflows/integration_tests_validation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -24,19 +24,12 @@ jobs:
if: ${{ !contains(needs.changes.outputs.dirs, '[]') }}
runs-on: ubuntu-20.04
timeout-minutes: 15
strategy:
matrix:
rust: [1.65.0, 1.66.0]
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
override: true
- name: Cache youki
uses: Swatinem/rust-cache@v1
- run: sudo apt-get -y update
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]
- name: Install requirements
run: ./.github/scripts/dependency.sh
- name: Install runc 1.1.0
run: |
wget -q https://github.com/opencontainers/runc/releases/download/v1.1.0/runc.amd64
Expand Down
65 changes: 23 additions & 42 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,75 +24,60 @@ jobs:
tests/rust-integration-tests/runtimetest: ./tests/rust-integration-tests/runtimetest
tests/rust-integration-tests/integration_test: ./tests/rust-integration-tests/integration_test
tests/rust-integration-tests/test_framework: ./tests/rust-integration-tests/test_framework
check:
needs: [changes]
if: ${{ !contains(needs.changes.outputs.dirs, '[]') }}
runs-on: ubuntu-20.04
timeout-minutes: 15
strategy:
matrix:
rust: [1.65.0, 1.66.0]
dirs: ${{ fromJSON(needs.changes.outputs.dirs) }}
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
override: true
- name: Cache youki
uses: Swatinem/rust-cache@v1
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]
- run: rustup component add rustfmt clippy
- run: sudo apt-get -y update
- name: Install requirements
run: ./.github/scripts/dependency.sh
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev
- name: Check formatting
run: cargo fmt --all -- --check
working-directory: ${{matrix.dirs}}
- name: Check clippy lints
working-directory: ${{matrix.dirs}}
run: cargo clippy --all-targets --all-features -- -D warnings

tests:
runs-on: ubuntu-20.04
timeout-minutes: 15
strategy:
matrix:
rust: [1.65.0, 1.66.0]
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
override: true
- name: Cache youki
uses: Swatinem/rust-cache@v1
- name: Install rus
run: rustup show
- run: sudo apt-get -y update
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev
- name: Run tests
run: |
export LD_LIBRARY_PATH=$HOME/.wasmedge/lib
cd ./crates && cargo test --all --all-features --no-fail-fast
coverage:
runs-on: ubuntu-20.04
timeout-minutes: 15
name: Run test coverage
steps:
- uses: actions/checkout@v3
- name: Toolchain setup
uses: actions-rs/toolchain@v1
with:
toolchain: 1.65.0
override: true
profile: minimal
components: llvm-tools-preview
- name: Cache youki
uses: Swatinem/rust-cache@v1
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]
- name: Install llvm-tools-preview
run: rustup component add llvm-tools-preview
- name: install cargo-llvm-cov
uses: taiki-e/install-action@v1
with:
tool: [email protected]
- name: Update System Libraries
run: sudo apt-get -y update
- name: Install System Libraries
run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev
- name: Install requirements
run: ./.github/scripts/dependency.sh
- name: Run Test Coverage for youki
run: |
cargo llvm-cov clean --workspace
Expand All @@ -102,27 +87,23 @@ jobs:
uses: codecov/codecov-action@v2
with:
file: ./coverage.lcov

integration_tests:
runs-on: ubuntu-20.04
timeout-minutes: 15
strategy:
matrix:
rust: [1.65.0, 1.66.0]
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- uses: actions-rs/toolchain@v1
with:
toolchain: ${{ matrix.rust }}
override: true
- name: Cache youki
uses: Swatinem/rust-cache@v1
- run: sudo apt-get -y update
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev
- uses: actions/setup-go@v2
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]
- name: Install requirements
run: ./.github/scripts/dependency.sh
- uses: actions/setup-go@v3
with:
go-version: "1.17.6"
cache: true
cache-dependency-path: tests/oci-runtime-tests/src/github.com/opencontainers/runtime-tools/go.sum
- name: Build
run: make youki-release
- name: Run integration tests
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/podman_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@ jobs:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- run: sudo apt-get -y update
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev libgpgme-dev bats
- name: Install requirements
run: ./.github/scripts/dependency.sh
- run: make youki-dev
- run: sudo cp youki /usr/local/bin
- name: Clone podman repository
Expand Down
27 changes: 10 additions & 17 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,11 @@ jobs:
- uses: actions/checkout@v3
with:
submodules: recursive
- run: sudo apt-get -y update
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev libclang-dev
- name: Install requirements
run: ./.github/scripts/dependency.sh
- name: Set up cargo
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]
- name: Build
run: make youki-release
- name: test
Expand All @@ -30,13 +28,11 @@ jobs:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- run: sudo apt-get -y update
- run: sudo apt-get install -y pkg-config libsystemd-dev libdbus-glib-1-dev libelf-dev libseccomp-dev
- name: Install requirements
run: ./.github/scripts/dependency.sh
- name: Set up cargo
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]
- name: Release build
run: make youki-release
- name: Create output directory
Expand Down Expand Up @@ -104,11 +100,8 @@ jobs:
CARGO_REGISTRY_TOKEN: ${{ secrets.CARGO_REGISTRY_TOKEN }}
steps:
- uses: actions/checkout@v3
- name: Set up cargo
uses: actions-rs/toolchain@v1
with:
toolchain: stable
override: true
- name: Setup Rust toolchain and cache
uses: actions-rust-lang/[email protected]
- name: Publish libcgroups
run: cargo publish -p libcgroups --no-verify
- name: Publish libcontainer
Expand Down
Loading

0 comments on commit f2a55e5

Please sign in to comment.