feat(proto): define storage bucket state in worker status
This commit is contained in:
1 parent
dc21e714a5
commit
88c67e4eea
12 files changed
+1133
-216
No files matched your search
@@ -97,3 +97,30 @@ message WorkerTag {
|
||||
// @inject_tag: `gorm:"primary_key"`
|
||||
string source = 40;
|
||||
}
|
||||
|
||||
// WorkerStorageBucketCredentialState is a state for a storage bucket credential for a worker.
|
||||
// The primary key is comprised of the worker_id, storage_bucket_credential_id, permission_type.
|
||||
message WorkerStorageBucketCredentialState {
|
||||
// worker_id is the public key of the worker.
|
||||
// @inject_tag: `gorm:"primary_key"`
|
||||
string worker_id = 10;
|
||||
|
||||
// storage_bucket_credential_id is the public key of the storage bucket credential.
|
||||
// @inject_tag: `gorm:"primary_key"`
|
||||
string storage_bucket_credential_id = 20;
|
||||
|
||||
// permission_type is a enum that defines the permission type.
|
||||
// @inject_tag: `gorm:"primary_key"`
|
||||
string permission_type = 30;
|
||||
|
||||
// state is a enum that defines the permission state.
|
||||
// @inject_tag: `gorm:"not_null"`
|
||||
string state = 40;
|
||||
|
||||
// error_details is the error message returned from the external object store service.
|
||||
string error_details = 50;
|
||||
|
||||
// checked_at is the utc timestamp of when the permission was tested.
|
||||
// @inject_tag: `gorm:"not_null"`
|
||||
timestamp.v1.Timestamp checked_at = 60;
|
||||
}
|
||||
@@ -71,6 +71,10 @@ message StorageBucket {
|
||||
// secrets_hmac is a sha256-hmac of the unencrypted secrets stored in the db.
|
||||
// @inject_tag: `gorm:"default:null"`
|
||||
bytes secrets_hmac = 13;
|
||||
|
||||
// storage_bucket_credential_id is the private key of the storage bucket credential.
|
||||
// @inject_tag: `gorm:"default:null"`
|
||||
string storage_bucket_credential_id = 14;
|
||||
}
|
||||
|
||||
message StorageBucketSecret {
|
||||
@@ -92,3 +96,47 @@ message StorageBucketSecret {
|
||||
// @inject_tag: `gorm:"not_null"`
|
||||
string key_id = 4;
|
||||
}
|
||||
|
||||
message StorageBucketCredential {
|
||||
// private_id is a surrogate key suitable for use via API.
|
||||
// @inject_tag: `gorm:"primary_key"`
|
||||
string private_id = 1;
|
||||
|
||||
// storage_bucket_id is the public id of the storage bucket.
|
||||
// @inject_tag: `gorm:"not_null"`
|
||||
string storage_bucket_id = 2;
|
||||
}
|
||||
|
||||
message StorageBucketCredentialEnvironmental {
|
||||
// private_id is a surrogate key suitable for use in a public API.
|
||||
// @inject_tag: `gorm:"primary_key"`
|
||||
string private_id = 1;
|
||||
|
||||
// storage_bucket_id is the public id of the storage bucket.
|
||||
// @inject_tag: `gorm:"not_null"`
|
||||
string storage_bucket_id = 2;
|
||||
}
|
||||
|
||||
message StorageBucketCredentialManagedSecret {
|
||||
// private_id is a surrogate key suitable for use via API.
|
||||
// @inject_tag: `gorm:"primary_key"`
|
||||
string private_id = 1;
|
||||
|
||||
// storage_bucket_id is the public id of the storage bucket.
|
||||
// @inject_tag: `gorm:"not_null"`
|
||||
string storage_bucket_id = 2;
|
||||
|
||||
// secrets is the plain-text of the secret data. We are not storing this plain-text
|
||||
// value in the database.
|
||||
// @inject_tag: `gorm:"-" wrapping:"pt,secrets_data"`
|
||||
bytes secrets = 3;
|
||||
|
||||
// ct_secrets is the ciphertext of the secret data stored in the db.
|
||||
// @inject_tag: `gorm:"column:secrets_encrypted;not_null" wrapping:"ct,secrets_data"`
|
||||
bytes ct_secrets = 4;
|
||||
|
||||
// The key_id of the kms database key used for encrypting this entry.
|
||||
// It must be set.
|
||||
// @inject_tag: `gorm:"not_null"`
|
||||
string key_id = 5;
|
||||
}
|
||||
Reference in new issue
Block a user