Skip to content

Commit

Permalink
Merge branch 'main' into fix-schema-tests
Browse files Browse the repository at this point in the history
  • Loading branch information
smklein committed Sep 29, 2023
2 parents 592a798 + 8a11c70 commit 3c59d61
Show file tree
Hide file tree
Showing 175 changed files with 3,123 additions and 2,015 deletions.
29 changes: 29 additions & 0 deletions .config/hakari.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# This file contains settings for `cargo hakari`.
# See https://docs.rs/cargo-hakari/latest/cargo_hakari/config for a full list of options.

hakari-package = "omicron-workspace-hack"

# Format for `workspace-hack = ...` lines in other Cargo.tomls. Requires cargo-hakari 0.9.8 or above.
dep-format-version = "4"

# Setting workspace.resolver = "2" in the root Cargo.toml is HIGHLY recommended.
# Hakari works much better with the new feature resolver.
# For more about the new feature resolver, see:
# https://blog.rust-lang.org/2021/03/25/Rust-1.51.0.html#cargos-new-feature-resolver
resolver = "2"

# Add triples corresponding to platforms commonly used by developers here.
# https://doc.rust-lang.org/rustc/platform-support.html
platforms = [
"x86_64-unknown-linux-gnu",
"x86_64-apple-darwin",
"aarch64-apple-darwin",
"x86_64-unknown-illumos",
# "x86_64-pc-windows-msvc",
]

[traversal-excludes]
workspace-members = ["xtask"]

# Write out exact versions rather than a semver range. (Defaults to false.)
# exact-versions = true
11 changes: 10 additions & 1 deletion .config/nextest.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,16 @@
#
# The required version should be bumped up if we need new features, performance
# improvements or bugfixes that are present in newer versions of nextest.
nextest-version = { required = "0.9.55", recommended = "0.9.57" }
nextest-version = { required = "0.9.59", recommended = "0.9.59" }

experimental = ["setup-scripts"]

[[profile.default.scripts]]
filter = 'rdeps(nexus-test-utils)'
setup = 'crdb-seed'

[profile.ci]
fail-fast = false

[script.crdb-seed]
command = 'cargo run -p crdb-seed'
7 changes: 6 additions & 1 deletion .github/buildomat/build-and-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ set -o xtrace
# NOTE: This version should be in sync with the recommended version in
# .config/nextest.toml. (Maybe build an automated way to pull the recommended
# version in the future.)
NEXTEST_VERSION='0.9.57'
NEXTEST_VERSION='0.9.59'

cargo --version
rustc --version
Expand Down Expand Up @@ -66,6 +66,11 @@ ptime -m timeout 2h cargo nextest run --profile ci --locked --verbose
banner doctest
ptime -m timeout 1h cargo test --doc --locked --verbose --no-fail-fast

# We expect the seed CRDB to be placed here, so we explicitly remove it so the
# rmdir check below doesn't get triggered. Nextest doesn't have support for
# teardown scripts so this is the best we've got.
rm -rf "$TEST_TMPDIR/crdb-base"

#
# Make sure that we have left nothing around in $TEST_TMPDIR. The easiest way
# to check is to try to remove it with `rmdir`.
Expand Down
2 changes: 1 addition & 1 deletion .github/buildomat/jobs/build-and-test-helios.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#: name = "build-and-test (helios)"
#: variety = "basic"
#: target = "helios-2.0"
#: rust_toolchain = "1.72.0"
#: rust_toolchain = "1.72.1"
#: output_rules = [
#: "/var/tmp/omicron_tmp/*",
#: "!/var/tmp/omicron_tmp/crdb-base*",
Expand Down
2 changes: 1 addition & 1 deletion .github/buildomat/jobs/build-and-test-linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#: name = "build-and-test (ubuntu-20.04)"
#: variety = "basic"
#: target = "ubuntu-20.04"
#: rust_toolchain = "1.72.0"
#: rust_toolchain = "1.72.1"
#: output_rules = [
#: "/var/tmp/omicron_tmp/*",
#: "!/var/tmp/omicron_tmp/crdb-base*",
Expand Down
2 changes: 1 addition & 1 deletion .github/buildomat/jobs/ci-tools.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#: name = "helios / CI tools"
#: variety = "basic"
#: target = "helios-2.0"
#: rust_toolchain = "1.72.0"
#: rust_toolchain = "1.72.1"
#: output_rules = [
#: "=/work/end-to-end-tests/*.gz",
#: "=/work/caboose-util.gz",
Expand Down
2 changes: 1 addition & 1 deletion .github/buildomat/jobs/clippy.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#: name = "clippy (helios)"
#: variety = "basic"
#: target = "helios-2.0"
#: rust_toolchain = "1.72.0"
#: rust_toolchain = "1.72.1"
#: output_rules = []

# Run clippy on illumos (not just other systems) because a bunch of our code
Expand Down
2 changes: 1 addition & 1 deletion .github/buildomat/jobs/host-image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#: name = "helios / build OS image"
#: variety = "basic"
#: target = "helios-2.0"
#: rust_toolchain = "1.72.0"
#: rust_toolchain = "1.72.1"
#: output_rules = [
#: "=/work/helios/image/output/os.tar.gz",
#: ]
Expand Down
2 changes: 1 addition & 1 deletion .github/buildomat/jobs/package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#: name = "helios / package"
#: variety = "basic"
#: target = "helios-2.0"
#: rust_toolchain = "1.72.0"
#: rust_toolchain = "1.72.1"
#: output_rules = [
#: "=/work/version.txt",
#: "=/work/package.tar.gz",
Expand Down
2 changes: 1 addition & 1 deletion .github/buildomat/jobs/trampoline-image.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
#: name = "helios / build trampoline OS image"
#: variety = "basic"
#: target = "helios-2.0"
#: rust_toolchain = "1.72.0"
#: rust_toolchain = "1.72.1"
#: output_rules = [
#: "=/work/helios/image/output/os.tar.gz",
#: ]
Expand Down
37 changes: 37 additions & 0 deletions .github/workflows/hakari.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# This workflow file serves as an example for cargo-hakari CI integration.

on:
push:
branches:
- main
pull_request:
branches:
- main

name: cargo hakari

jobs:
workspace-hack-check:
name: Check workspace-hack
runs-on: ubuntu-latest
env:
RUSTFLAGS: -D warnings
steps:
- uses: actions/checkout@v4
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
- name: Install cargo-hakari
uses: taiki-e/install-action@v2
with:
tool: cargo-hakari
- name: Check workspace-hack Cargo.toml is up-to-date
uses: actions-rs/cargo@v1
with:
command: hakari
args: generate --diff
- name: Check all crates depend on workspace-hack
uses: actions-rs/cargo@v1
with:
command: hakari
args: manage-deps --dry-run
Loading

0 comments on commit 3c59d61

Please sign in to comment.