Add github action to run e2e test with kubernetes cluster. #1986
Workflow file for this run
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
name: Validation | |
on: | |
workflow_dispatch: {} | |
pull_request: | |
types: [opened, synchronize, reopened] | |
schedule: | |
- cron: "00 00 * * 1" | |
jobs: | |
validation: | |
name: Validation | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
submodules: recursive | |
- name: Configure sccache | |
uses: actions/github-script@v6 | |
with: | |
script: | | |
core.exportVariable('ACTIONS_CACHE_URL', process.env.ACTIONS_CACHE_URL || ''); | |
core.exportVariable('ACTIONS_RUNTIME_TOKEN', process.env.ACTIONS_RUNTIME_TOKEN || ''); | |
- name: Build xline | |
run: | | |
docker run -q --rm -v $(pwd):/xline \ | |
-e SCCACHE_GHA_ENABLED=on \ | |
-e ACTIONS_CACHE_URL=${ACTIONS_CACHE_URL} \ | |
-e ACTIONS_RUNTIME_TOKEN=${ACTIONS_RUNTIME_TOKEN} \ | |
ghcr.io/xline-kv/build-env:latest \ | |
cargo build --release --bin xline --bin benchmark --bin validation_lock_client | |
- run: | | |
sudo apt-get install -y --force-yes expect | |
cd scripts | |
cp ../target/release/{xline,benchmark,validation_lock_client} . | |
ldd ./xline | |
ldd ./benchmark | |
cp ../fixtures/{private,public}.pem . | |
docker build . -t ghcr.io/xline-kv/xline:latest | |
docker pull gcr.io/etcd-development/etcd:v3.5.5 | |
bash ./validation_test.sh | |
- name: upload logs | |
if: failure() || cancelled() | |
uses: actions/upload-artifact@v1 | |
with: | |
name: Xline logs | |
path: scripts/logs |