-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f…
…8d1ac.tgz object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/README.md object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/main.yaml object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/values.schema.json
- Loading branch information
1 parent
1b88ef8
commit fe95223
Showing
5 changed files
with
229 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file added
BIN
+5.13 KB
object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz
Binary file not shown.
51 changes: 51 additions & 0 deletions
51
...rage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/README.md
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,51 @@ | ||
# Controllers | ||
|
||
## Bucket controller | ||
|
||
This controller reconciles `Buckets`. It creates a cloud provider bucket in the Management Cluster Region. | ||
It currently only supports AWS S3 on CAPA management clusters and Azure Storage Container on CAPZ management clusters. | ||
|
||
### CAPZ resources | ||
|
||
To handle an object storage on Azure, we need to create: | ||
|
||
- a storage account | ||
- a storage container | ||
|
||
We choose to create a unique relation Storage Account - Storage Container to have a proper clean up when a bucket is deleted. This way, there won't have orphan storage account on Azure. | ||
|
||
We add a lifecyle management rule on the storage account to clean old data (`bucket.spec.expirationPolicy.days`) | ||
|
||
When the object storage is created, we retrieve the Access Key and create a secret in the bucket namespace containing the name of the storage account and the access key. This secret is necessary for the application desiring to use this object storage. | ||
|
||
By default, a reclaim policy is set to `reclaimPolicy: Retain` that means when a Bucket CR is deleted, nothing is done. The idea is to avoid accidental Bucket CR deletions that result in data loss on the Cloud provider. | ||
However, if we need to clean up the bucket, we can set the reclaim policy to `reclaimPolicy: Delete`. This will remove all data on the Cloud provider. | ||
|
||
# Testing | ||
|
||
You can run all tests with | ||
|
||
``` | ||
make test-all | ||
``` | ||
|
||
## Unit tests | ||
|
||
You can run only the unit tests with | ||
|
||
``` | ||
make test-unit | ||
``` | ||
|
||
## Integration tests | ||
|
||
You can run only the integration tests with | ||
|
||
``` | ||
make test-integration | ||
``` | ||
|
||
This project uses [`LocalStack`](https://github.com/localstack/localstack) for integration tests. Remember that you can use the `aws` cli targetting the local [`LocalStack`](https://github.com/localstack/localstack) environment with | ||
``` | ||
$ aws --endpoint=http://localhost:4566 s3 list-buckets | ||
``` |
12 changes: 12 additions & 0 deletions
12
object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/main.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
annotations: | ||
application.giantswarm.io/metadata: https://giantswarm.github.io/control-plane-test-catalog/object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/main.yaml | ||
application.giantswarm.io/readme: https://giantswarm.github.io/control-plane-test-catalog/object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/README.md | ||
application.giantswarm.io/team: atlas | ||
application.giantswarm.io/values-schema: https://giantswarm.github.io/control-plane-test-catalog/object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/values.schema.json | ||
config.giantswarm.io/version: 1.x.x | ||
chartApiVersion: v2 | ||
chartFile: object-storage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz | ||
dateCreated: '2024-12-03T21:03:30.911324Z' | ||
digest: 5c79d202cfa96536992e2d8b59eb3bd1fa2bd3dd74386f171fbe05f57d2d6dbe | ||
home: https://github.com/giantswarm/object-storage-operator | ||
icon: https://s.giantswarm.io/app-icons/giantswarm/1/light.svg |
147 changes: 147 additions & 0 deletions
147
...orage-operator-0.9.0-417716481ef55a988e062507a36cdaff08f8d1ac.tgz-meta/values.schema.json
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,147 @@ | ||
{ | ||
"$schema": "http://json-schema.org/schema#", | ||
"type": "object", | ||
"properties": { | ||
"aws": { | ||
"type": "object", | ||
"properties": { | ||
"accessKeyID": { | ||
"type": "string" | ||
}, | ||
"secretAccessKey": { | ||
"type": "string" | ||
} | ||
} | ||
}, | ||
"containerSecurityContext": { | ||
"type": "object", | ||
"properties": { | ||
"allowPrivilegeEscalation": { | ||
"type": "boolean" | ||
}, | ||
"capabilities": { | ||
"type": "object", | ||
"properties": { | ||
"drop": { | ||
"type": "array", | ||
"items": { | ||
"type": "string" | ||
} | ||
} | ||
} | ||
}, | ||
"readOnlyRootFilesystem": { | ||
"type": "boolean" | ||
}, | ||
"seccompProfile": { | ||
"type": "object", | ||
"properties": { | ||
"type": { | ||
"type": "string" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"global": { | ||
"type": "object", | ||
"properties": { | ||
"podSecurityStandards": { | ||
"type": "object", | ||
"properties": { | ||
"enforced": { | ||
"type": "boolean" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"image": { | ||
"type": "object", | ||
"properties": { | ||
"registry": { | ||
"type": "string" | ||
}, | ||
"repository": { | ||
"type": "string" | ||
}, | ||
"tag": { | ||
"type": "string" | ||
} | ||
} | ||
}, | ||
"managementCluster": { | ||
"type": "object", | ||
"properties": { | ||
"name": { | ||
"type": "string" | ||
}, | ||
"namespace": { | ||
"type": "string" | ||
}, | ||
"provider": { | ||
"type": "object", | ||
"properties": { | ||
"kind": { | ||
"type": "string" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"networkPolicy": { | ||
"type": "object", | ||
"properties": { | ||
"flavor": { | ||
"type": "string" | ||
} | ||
} | ||
}, | ||
"podSecurityContext": { | ||
"type": "object", | ||
"properties": { | ||
"runAsNonRoot": { | ||
"type": "boolean" | ||
}, | ||
"runAsUser": { | ||
"type": "integer" | ||
}, | ||
"seccompProfile": { | ||
"type": "object", | ||
"properties": { | ||
"type": { | ||
"type": "string" | ||
} | ||
} | ||
} | ||
} | ||
}, | ||
"resources": { | ||
"type": "object", | ||
"properties": { | ||
"limits": { | ||
"type": "object", | ||
"properties": { | ||
"cpu": { | ||
"type": "string" | ||
}, | ||
"memory": { | ||
"type": "string" | ||
} | ||
} | ||
}, | ||
"requests": { | ||
"type": "object", | ||
"properties": { | ||
"cpu": { | ||
"type": "string" | ||
}, | ||
"memory": { | ||
"type": "string" | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} | ||
} |