Skip to content

Commit c1e5128

Browse files
authored
ci(cubestore): Run workflow in container (#9422)
* ci(cubestore): Run CI workflow in container * ci(cubestore): Remove jobs limit for build and test * ci(cubestore): Setup TMPDIR explicitly * test(cubestore): Bump test timeout to account for data.wprdc.org slowness
1 parent 421fccc commit c1e5128

File tree

3 files changed

+14
-19
lines changed

3 files changed

+14
-19
lines changed

.github/workflows/rust-cubestore.yml

Lines changed: 12 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -27,25 +27,14 @@ jobs:
2727
fail-fast: false
2828
matrix:
2929
rust: [nightly-2024-01-29]
30+
container:
31+
image: cubejs/rust-builder:bookworm-llvm-18
3032
env:
3133
RUST: ${{ matrix.rust }}
3234
steps:
33-
- name: Maximize build space (disk space limitations)
34-
run: |
35-
echo "Before"
36-
df -h
37-
sudo apt-get remove -y 'php.*'
38-
sudo apt-get remove -y '^mongodb-.*'
39-
sudo apt-get remove -y '^mysql-.*'
40-
sudo apt-get autoremove -y
41-
sudo apt-get clean
42-
43-
sudo rm -rf /usr/share/dotnet
44-
sudo rm -rf /usr/local/lib/android
45-
sudo rm -rf /opt/ghc
46-
sudo rm -rf /opt/hostedtoolcache/CodeQL
47-
echo "After"
48-
df -h
35+
- name: Prepare directories
36+
# See TMPDIR comment below
37+
run: mkdir /__w/tmp
4938
- name: Checkout
5039
uses: actions/checkout@v4
5140
- name: Install Rust
@@ -69,10 +58,15 @@ jobs:
6958
cargo fmt --manifest-path rust/cubestore/cubehll/Cargo.toml -- --check
7059
- name: Run cargo build
7160
run: |
72-
cargo build --manifest-path rust/cubestore/Cargo.toml -j 4
61+
cargo build --manifest-path rust/cubestore/Cargo.toml
7362
- name: Run cargo test
63+
env:
64+
# LocalDirRemoteFs expect that std::env::temp_dir and its local dir is on same FS, to use `rename`
65+
# On Unix it's controlled by TMPDIR
66+
# When using `container` in GHA checkout will be located in `/__w`, and that's a separate mount from `/tmp`
67+
TMPDIR: /__w/tmp
7468
run: |
75-
cargo test --manifest-path rust/cubestore/Cargo.toml -j 1
69+
cargo test --manifest-path rust/cubestore/Cargo.toml
7670
7771
docker-image-latest:
7872
name: Build only :latest image

rust/cubestore/cubestore-sql-tests/src/multiproc.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ pub trait MultiProcTest {
113113

114114
/// This timeout will be applied both on worker and for the drive() function.
115115
fn timeout(&self) -> Duration {
116-
Duration::from_secs(20)
116+
Duration::from_secs(30)
117117
}
118118

119119
fn worker_init_timeout(&self) -> Duration {

rust/cubestore/cubestore-sql-tests/src/tests.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2256,6 +2256,7 @@ async fn create_table_with_csv_no_header_and_delimiter(service: Box<dyn SqlClien
22562256
}
22572257

22582258
async fn create_table_with_url(service: Box<dyn SqlClient>) {
2259+
// TODO serve this data ourselves
22592260
let url = "https://data.wprdc.org/dataset/0b584c84-7e35-4f4d-a5a2-b01697470c0f/resource/e95dd941-8e47-4460-9bd8-1e51c194370b/download/bikepghpublic.csv";
22602261

22612262
service

0 commit comments

Comments
 (0)