Skip to content

Commit

Permalink
fix: inject s3 bucket into cas config (#181)
Browse files Browse the repository at this point in the history
  • Loading branch information
smrz2001 committed May 21, 2024
1 parent 7a4b051 commit fa4e31b
Show file tree
Hide file tree
Showing 3 changed files with 19 additions and 6 deletions.
5 changes: 5 additions & 0 deletions operator/src/network/cas.rs
Original file line number Diff line number Diff line change
Expand Up @@ -270,6 +270,11 @@ pub fn cas_stateful_set_spec(
value: Some("s3".to_owned()),
..Default::default()
},
EnvVar {
name: "S3_BUCKET_NAME".to_owned(),
value: Some("ceramic-dev-cas".to_owned()),
..Default::default()
},
EnvVar {
name: "S3_ENDPOINT".to_owned(),
value: Some("http://localstack:4566".to_owned()),
Expand Down
12 changes: 6 additions & 6 deletions operator/src/network/controller.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2817,7 +2817,7 @@ mod tests {
stub.cas_stateful_set.patch(expect![[r#"
--- original
+++ modified
@@ -130,8 +130,8 @@
@@ -134,8 +134,8 @@
"value": "http://localstack:4566/000000000000/cas-anchor-dev-"
}
],
Expand All @@ -2828,7 +2828,7 @@ mod tests {
"name": "cas-api",
"ports": [
{
@@ -264,8 +264,8 @@
@@ -272,8 +272,8 @@
"value": "false"
}
],
Expand All @@ -2839,7 +2839,7 @@ mod tests {
"name": "cas-worker",
"resources": {
"limits": {
@@ -434,8 +434,8 @@
@@ -442,8 +442,8 @@
"value": "dev"
}
],
Expand Down Expand Up @@ -2915,7 +2915,7 @@ mod tests {
stub.cas_stateful_set.patch(expect![[r#"
--- original
+++ modified
@@ -140,12 +140,12 @@
@@ -144,12 +144,12 @@
],
"resources": {
"limits": {
Expand All @@ -2930,7 +2930,7 @@ mod tests {
"ephemeral-storage": "1Gi",
"memory": "1Gi"
}
@@ -269,12 +269,12 @@
@@ -277,12 +277,12 @@
"name": "cas-worker",
"resources": {
"limits": {
Expand All @@ -2945,7 +2945,7 @@ mod tests {
"ephemeral-storage": "1Gi",
"memory": "1Gi"
}
@@ -357,12 +357,12 @@
@@ -365,12 +365,12 @@
"name": "cas-scheduler",
"resources": {
"limits": {
Expand Down
8 changes: 8 additions & 0 deletions operator/src/network/testdata/default_stubs/cas_stateful_set
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,10 @@ Request {
"name": "NODE_ENV",
"value": "dev"
},
{
"name": "S3_BUCKET_NAME",
"value": "ceramic-dev-cas"
},
{
"name": "S3_ENDPOINT",
"value": "http://localstack:4566"
Expand Down Expand Up @@ -231,6 +235,10 @@ Request {
"name": "MERKLE_CAR_STORAGE_MODE",
"value": "s3"
},
{
"name": "S3_BUCKET_NAME",
"value": "ceramic-dev-cas"
},
{
"name": "S3_ENDPOINT",
"value": "http://localstack:4566"
Expand Down

0 comments on commit fa4e31b

Please sign in to comment.