add tarf #40
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: Rust | |
on: | |
push: | |
branches: [ "main" ] | |
pull_request: | |
branches: [ "main" ] | |
env: | |
CARGO_TERM_COLOR: always | |
jobs: | |
build_and_test: | |
name: Build and Test | |
runs-on: ubuntu-latest | |
services: | |
cassandra: | |
image: cassandra | |
ports: | |
- 9042:9042 | |
options: --health-cmd "cqlsh --debug" --health-interval 5s --health-retries 100 | |
steps: | |
- uses: actions/checkout@v3 | |
- name: protobuf install | |
run: | | |
sudo apt-get install -y protobuf-compiler libprotobuf-dev | |
- name: Build | |
run: cargo build | |
- name: Prepare / Save test private key file from secrets | |
run: envsubst < private.key.envsubst.txt > private.key | |
env: | |
TEST_PRIVATE_SERVER_KEY: ${{ secrets.TEST_PRIVATE_SERVER_KEY }} | |
- name: Test / Save test cert file from secrets | |
run: envsubst < server.crt.envsubst.txt > server.crt | |
env: | |
TEST_SERVER_CERT: ${{ secrets.TEST_SERVER_CERT }} | |
- name: Test / Run tests | |
run: cargo test -- --nocapture |