Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
49 commits
Select commit Hold shift + click to select a range
5fbeba5
feat: derive default credentials from aws sdk
baszalmstra Aug 20, 2025
5cc3761
fix: cleanup unused features
baszalmstra Aug 20, 2025
5f09edd
Merge remote-tracking branch 'upstream/main' into rattler-index-defau…
baszalmstra Aug 25, 2025
ed87abb
fix: enable using s3 default credentials with s3middelware
baszalmstra Aug 25, 2025
f12aca4
upload and fetch too
baszalmstra Aug 26, 2025
487a109
fix: dont error on precondition failure
baszalmstra Aug 26, 2025
a3067f8
fix: test compilation and pre-commit
baszalmstra Aug 26, 2025
d92dcaa
fix: README
baszalmstra Aug 26, 2025
d3357cb
fix: update py-rattler
baszalmstra Aug 26, 2025
32bb14a
test: add minio test
baszalmstra Aug 26, 2025
ccfb957
test: use github actions
baszalmstra Aug 26, 2025
a4a3f32
test: fix sha
baszalmstra Aug 26, 2025
c4ecb71
fix: precommit
baszalmstra Aug 26, 2025
6253387
simpler minio
baszalmstra Aug 26, 2025
c6107fc
simpler minio
baszalmstra Aug 26, 2025
1d4314e
dont use pixi
baszalmstra Aug 26, 2025
0e3bf67
fix: cli args
baszalmstra Aug 26, 2025
061f63b
fix: setup role
baszalmstra Aug 26, 2025
903b99a
fix: enable ss3
baszalmstra Aug 26, 2025
413342c
fix: s3
baszalmstra Aug 26, 2025
e4c7f00
fix: s3 bucket name
baszalmstra Aug 26, 2025
ac3cc09
Merge remote-tracking branch 'upstream/main' into rattler-index-defau…
baszalmstra Aug 28, 2025
476d252
test: use pixi for e2e minio test
baszalmstra Aug 28, 2025
38ec607
fix: globs of rust backend
baszalmstra Aug 28, 2025
f58a0ae
fix: locked versions
baszalmstra Aug 28, 2025
4ef1fba
test: enable sccache and fix sha
baszalmstra Aug 28, 2025
5f5b403
fix: aws test script
baszalmstra Aug 28, 2025
6daf82f
fix: broken workflow
baszalmstra Aug 28, 2025
a188046
fix: update pixi.lock
baszalmstra Aug 28, 2025
430f8a7
fix: streamline s3 access
baszalmstra Aug 28, 2025
94aa024
fix: pre-commit
baszalmstra Aug 28, 2025
43e687d
cleaned up python bindings
baszalmstra Sep 2, 2025
fbbe4e5
fix: cleanup pixi lock
baszalmstra Sep 2, 2025
2bbc46d
fix: update lockfile
baszalmstra Sep 2, 2025
8d32bff
fix: update lockfile
baszalmstra Sep 2, 2025
756812d
Merge remote-tracking branch 'upstream/main' into rattler-index-defau…
baszalmstra Sep 2, 2025
c82ba82
Update .github/workflows/e2e-s3-tests.yml
baszalmstra Sep 2, 2025
1c9f3d5
fix: update cargo lockfile
baszalmstra Sep 2, 2025
65ecf07
fix: update lockfile
baszalmstra Sep 2, 2025
c836671
fix: linting
baszalmstra Sep 2, 2025
37ad55a
feat: read version from cargo.toml
baszalmstra Sep 2, 2025
866a119
fix: formatting issues
baszalmstra Sep 2, 2025
55feb95
fix: move force_path_style
baszalmstra Sep 4, 2025
2857213
dont use deprecated api
baszalmstra Sep 4, 2025
95a4d64
chore: remove provider name
baszalmstra Sep 4, 2025
3ffe37a
Update crates/rattler_s3/src/lib.rs
baszalmstra Sep 4, 2025
c398362
fix: integration test
baszalmstra Sep 4, 2025
4fd1eb9
Merge remote-tracking branch 'upstream/main' into rattler-index-defau…
baszalmstra Sep 4, 2025
2b92d8e
fix: struct ordering
baszalmstra Sep 4, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
87 changes: 87 additions & 0 deletions .github/workflows/e2e-s3-tests.yml
Copy link
Copy Markdown
Member

@pavelzw pavelzw Aug 27, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

while you're at it, what about adding cloudflare r2 integration tests as well in this file? @delsner and i definitely wrote some at some point, not sure whether in this repo or in pixi/rattler-build only.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it was in this repo:

#[fixture]
fn r2_host() -> String {
"https://e1a7cde76f1780ec06bac859036dbaf7.eu.r2.cloudflarestorage.com".into()
}
#[fixture]
fn r2_credentials() -> Option<(String, String)> {
let r2_access_key_id = std::env::var("RATTLER_TEST_R2_READONLY_ACCESS_KEY_ID").ok();
let r2_secret_access_key = std::env::var("RATTLER_TEST_R2_READONLY_SECRET_ACCESS_KEY").ok();
if r2_access_key_id.is_none()
|| r2_access_key_id.clone().unwrap().is_empty()
|| r2_secret_access_key.is_none()
|| r2_secret_access_key.clone().unwrap().is_empty()
{
eprintln!(
"Skipping test as RATTLER_TEST_R2_READONLY_ACCESS_KEY_ID or RATTLER_TEST_R2_READONLY_SECRET_ACCESS_KEY is not set"
);
None
} else {
Some((r2_access_key_id.unwrap(), r2_secret_access_key.unwrap()))
}
}

Original file line number Diff line number Diff line change
@@ -0,0 +1,87 @@
on:
push:
branches: [main]
pull_request:
paths:
- crates/rattler-bin/**
- crates/rattler_index/**
- crates/rattler_upload/**
- crates/rattler_networking/**
- .github/workflows/e2e-s3-tests.yml

name: E2E S3 Tests

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: false

env:
RUST_LOG: info
RUST_BACKTRACE: 1
CARGO_TERM_COLOR: always
DEFAULT_FEATURES: s3

jobs:
e2e-minio-test:
name: E2E Upload/Index/Download [Minio]
runs-on: ubuntu-latest

env:
# Enable sccache.
#
# This environment variable is picked up by pixi build which will then
# set up the rust build using sccache.
SCCACHE_GHA_ENABLED: "true"

steps:
- name: Checkout source code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
submodules: recursive

- uses: prefix-dev/setup-pixi@fef5c9568ca6c4ff7707bf840ab0692ba3f08293 # v0.9.0
with:
environments: minio

- run: pixi run e2e-s3-minio

# TODO: add cloudflare R2 integration tests here as well
e2e-aws-s3-test:
Comment thread
baszalmstra marked this conversation as resolved.
name: E2E Upload/Index/Download [AWS S3]
runs-on: ubuntu-latest
# Only run on main branch to avoid creating too many test buckets
# if: github.ref == 'refs/heads/main'
permissions:
id-token: write
contents: read

env:
# Enable sccache.
#
# This environment variable is picked up by pixi build which will then
# set up the rust build using sccache.
SCCACHE_GHA_ENABLED: "true"

# The region to create buckets it.
AWS_REGION: eu-west-1

# The name of the test bucket to create.
BUCKET: tmp-${{ github.repository_owner }}-${{ github.event.repository.name }}-${{ github.run_id }}-${{ github.run_attempt }}

steps:
- name: Checkout source code
uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4.2.2
with:
submodules: recursive

- name: Configure AWS (OIDC)
uses: aws-actions/configure-aws-credentials@7474bc4690e29a8392af63c5b98e7449536d5c3a # v4.3.1
with:
aws-region: ${{ env.AWS_REGION }}
role-to-assume: arn:aws:iam::239378270001:role/conda-rattler-e2e-test

- uses: prefix-dev/setup-pixi@fef5c9568ca6c4ff7707bf840ab0692ba3f08293 # v0.9.0
with:
environments: s3

- run: pixi run e2e-s3-aws
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,3 +26,6 @@ test-data/channels/conda-forge/

# Visual studio files
.vs/

# Local environment files
*.local.*
26 changes: 26 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

21 changes: 8 additions & 13 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ async-compression = { version = "0.4", features = [
] }
async-fd-lock = "0.2.0"
fs4 = "0.13.1"
async-once-cell = "0.5.4"
async-trait = "0.1.88"
axum = { version = "0.8.4", default-features = false, features = [
"tokio",
Expand All @@ -51,7 +52,7 @@ chrono = { version = "0.4.41", default-features = false, features = [
"serde",
"alloc",
] }
clap = { version = "4.5.38", features = ["derive"] }
clap = { version = "4.5.38", features = ["derive", "color", "suggestions", "error-context"] }
clap-verbosity-flag = "3.0.3"
cmake = "0.1.54"
console = { version = "0.16.0", features = ["windows-console-colors"] }
Expand All @@ -72,17 +73,9 @@ generic-array = "0.14.7"
getrandom = { version = "0.3.3", default-features = false }
glob = "0.3.2"
google-cloud-auth = { version = "0.22.0", default-features = false }
aws-config = { version = "=1.5.18", default-features = false, features = [
"rt-tokio",
"rustls",
"sso",
"credentials-process",
] }
aws-sdk-s3 = { version = "1.85.0", default-features = false, features = [
"rt-tokio",
"rustls",
"sigv4a",
] }
aws-config = { version = "=1.5.18", default-features = false }
aws-sdk-s3 = { version = "1.85.0", default-features = false }
Comment thread
pavelzw marked this conversation as resolved.
aws-credential-types = { version = "1.2.5", default-features = false }
hex = "0.4.3"
hex-literal = "1.0.0"
http = "1.3"
Expand Down Expand Up @@ -197,13 +190,15 @@ rattler_lock = { path = "crates/rattler_lock", version = "=0.24.0", default-feat
rattler_macros = { path = "crates/rattler_macros", version = "=1.0.11", default-features = false }
rattler_menuinst = { path = "crates/rattler_menuinst", version = "=0.2.24", default-features = false }
rattler_networking = { path = "crates/rattler_networking", version = "=0.25.11", default-features = false }
rattler_package_streaming = { path = "crates/rattler_package_streaming", version = "=0.23.2", default-features = false }
rattler_pty = { path = "crates/rattler_pty", version = "=0.2.6", default-features = false }
rattler_redaction = { path = "crates/rattler_redaction", version = "=0.1.12", default-features = false }
rattler_package_streaming = { path = "crates/rattler_package_streaming", version = "=0.23.2", default-features = false }
rattler_repodata_gateway = { path = "crates/rattler_repodata_gateway", version = "=0.24.2", default-features = false }
rattler_s3 = { path = "crates/rattler_s3", version = "=0.1.0", default-features = false }
rattler_sandbox = { path = "crates/rattler_sandbox", version = "=0.1.10", default-features = false }
rattler_shell = { path = "crates/rattler_shell", version = "=0.24.10", default-features = false }
rattler_solve = { path = "crates/rattler_solve", version = "=3.0.2", default-features = false }
rattler_upload = { path = "crates/rattler_upload", version = "=0.2.1", default-features = false }
rattler_virtual_packages = { path = "crates/rattler_virtual_packages", version = "=2.1.4", default-features = false }

# This is also a rattler crate, but we only pin it to minor version
Expand Down
2 changes: 2 additions & 0 deletions crates/rattler-bin/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,7 @@ anyhow = { workspace = true }
clap = { workspace = true, features = ["derive"] }
console = { workspace = true, features = ["windows-console-colors"] }
indicatif = { workspace = true }
miette = { workspace = true }
once_cell = { workspace = true }
rattler = { workspace = true, features = ["indicatif", "cli-tools"] }
rattler_conda_types = { workspace = true, default-features = false }
Expand All @@ -35,6 +36,7 @@ rattler_solve = { workspace = true, default-features = false, features = ["resol
rattler_virtual_packages = { workspace = true, default-features = false }
rattler_cache = { workspace = true, default-features = false }
rattler_menuinst = { workspace = true, default-features = false }
rattler_upload = { workspace = true, features = ["s3"]}
reqwest = { workspace = true, features = ["stream"] }
reqwest-middleware = { workspace = true }
tokio = { workspace = true, features = ["rt-multi-thread", "macros"] }
Expand Down
10 changes: 10 additions & 0 deletions crates/rattler-bin/pixi.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
[package]
name = "rattler"

[package.build.backend]
name = "pixi-build-rust"
version = "0.4.*"
channels = [
"https://prefix.dev/pixi-build-backends",
"https://prefix.dev/conda-forge"
]
6 changes: 3 additions & 3 deletions crates/rattler-bin/src/commands/auth.rs
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
use anyhow::Result;
use miette::IntoDiagnostic;
use rattler::cli::auth;

pub type Opt = auth::Args;

pub async fn auth(opt: Opt) -> Result<()> {
auth::execute(opt).await.map_err(|e| anyhow::anyhow!(e))
pub async fn auth(opt: Opt) -> miette::Result<()> {
auth::execute(opt).await.into_diagnostic()
}
Loading
Loading