Skip to content

Commit

Permalink
Merge branch 'master' into release/1.72
Browse files Browse the repository at this point in the history
  • Loading branch information
pjenvey committed Dec 17, 2024
2 parents 4663779 + 8cda9ac commit 7a6bdbd
Show file tree
Hide file tree
Showing 16 changed files with 885 additions and 508 deletions.
4 changes: 1 addition & 3 deletions .cargo/audit.toml
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
[advisories]
ignore = [
"RUSTSEC-2021-0124", # Bound by tokio restrictions, cargo, reqwest, hyper...
]
ignore = []
68 changes: 35 additions & 33 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ commands:
apt install build-essential curl libstdc++6 libstdc++-12-dev libssl-dev pkg-config -y
apt install cmake -y
# RUST_VER
curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain 1.81 -y
curl https://sh.rustup.rs -sSf | sh -s -- --default-toolchain 1.83 -y
export PATH=$PATH:$HOME/.cargo/bin
echo 'export PATH=$PATH:$HOME/.cargo/bin' >> $BASH_ENV
rustc --version
Expand Down Expand Up @@ -113,7 +113,7 @@ jobs:
audit:
docker:
# NOTE: update version for all # RUST_VER
- image: rust:1.81
- image: rust:1.83
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
Expand Down Expand Up @@ -154,50 +154,25 @@ jobs:

test-integration:
docker:
- image: python:3.12-slim-bookworm
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
- image: cimg/base:2024.06
environment:
RUST_BACKTRACE: 1
- image: google/cloud-sdk:latest
auth:
username: $DOCKER_USER
password: $DOCKER_PASS
command: gcloud beta emulators bigtable start --host-port=localhost:8086
resource_class: large
environment:
BIGTABLE_EMULATOR_HOST: localhost:8086
steps:
- checkout
- restore_test_cache:
cache_key: rust-v1-integration-test-{{ checksum "Cargo.lock" }}
- setup_remote_docker:
docker_layer_caching: true
- create_test_result_workspace
- setup_rust
- build_applications
- run:
name: Set up system
command: |
apt update
apt install libssl-dev apt-transport-https ca-certificates gnupg curl cmake -y
- setup_cbt
- setup_python
- setup_bigtable
- run:
name: Integration tests (Bigtable)
command: make integration-test
environment:
RUST_LOG: autopush=debug,autopush_common=debug,autoendpoint=debug,autoconnect=debug,slog_mozlog_json=info,warn
# PYTEST_ARGS: -sv
DB_DSN: grpc://localhost:8086
TEST_RESULTS_DIR: workspace/test-results
command: |
make integration-test
cp -r ~/project/tests/integration ~/project/workspace/test-results
- store_artifacts:
path: ~/project/workspace/test-results/integration_test_results.xml
destination: integration_test_results.xml
- store_test_results:
path: workspace/test-results
- save_test_cache:
cache_key: rust-v1-integration-test-cache-{{ checksum "Cargo.lock" }}

test-unit:
docker:
Expand Down Expand Up @@ -354,6 +329,26 @@ jobs:
paths:
- autopush-locust.tar

build-integration-test:
docker:
- image: cimg/base:2024.06
steps:
- checkout
- setup_remote_docker:
docker_layer_caching: true
- run:
name: Build Image
command: docker build -t autopush-integration-tests -f ./tests/integration/Dockerfile .
- run:
name: Save Docker Image to Workspace
command: |
mkdir -p /tmp/workspace
docker save -o /tmp/workspace/autopush-integration-tests.tar autopush-integration-tests
- persist_to_workspace:
root: /tmp/workspace
paths:
- autopush-integration-tests.tar

deploy:
executor: gcp-gcr/default
parameters:
Expand Down Expand Up @@ -481,6 +476,13 @@ workflows:
tags:
only: /.*/

- build-integration-test:
filters:
tags:
only: /.*/
branches:
only: master

# Comment out the following two sections for local CircleCI testing.
- deploy:
name: deploy-autoconnect
Expand Down
Loading

0 comments on commit 7a6bdbd

Please sign in to comment.