Add non-lab and a workflow
This commit is contained in:
parent
a7fad6c9c6
commit
94a24a45ed
5 changed files with 120 additions and 0 deletions
44
non-lab/backup.tf
Normal file
44
non-lab/backup.tf
Normal file
|
@ -0,0 +1,44 @@
|
|||
resource "b2_bucket" "cowley-tech-home-backup" {
|
||||
bucket_name = "cowley-tech-home-backup"
|
||||
bucket_type = "allPrivate"
|
||||
}
|
||||
|
||||
resource "b2_application_key" "user" {
|
||||
for_each = toset(["timothy", "nicolas"])
|
||||
|
||||
key_name = "cowley-tech-${each.key}-backup"
|
||||
bucket_id = b2_bucket.cowley-tech-home-backup.id
|
||||
capabilities = [
|
||||
"deleteFiles",
|
||||
"listBuckets",
|
||||
"listFiles",
|
||||
"readBuckets",
|
||||
"readFiles",
|
||||
"writeFiles",
|
||||
]
|
||||
}
|
||||
|
||||
resource "b2_application_key" "admin" {
|
||||
|
||||
key_name = "cowley-tech-admin-backup"
|
||||
bucket_id = b2_bucket.cowley-tech-home-backup.id
|
||||
capabilities = [
|
||||
"deleteFiles",
|
||||
"listBuckets",
|
||||
"listFiles",
|
||||
"readBuckets",
|
||||
"readFiles",
|
||||
"writeFiles",
|
||||
]
|
||||
}
|
||||
#
|
||||
#resource "kubernetes_secret" "b2-loki" {
|
||||
# metadata {
|
||||
# name = "b2-loki-credentials"
|
||||
# namespace = "logging"
|
||||
# }
|
||||
# data = {
|
||||
# B2_APPLICATION_KEY_ID = b2_application_key.loki.application_key_id
|
||||
# B2_APPLICATION_KEY = b2_application_key.loki.application_key
|
||||
# }
|
||||
#}
|
Loading…
Add table
Add a link
Reference in a new issue