Create a bucket ΒΆ
This guide will show you how to create a Google Cloud Storage bucket.
Add the bucket to the Nais application manifest ΒΆ
You create the bucket through the Nais application manifest.
Use a globally unique name
Bucket names must be globally unique across the entire Google infrastructure.
yaml
apiVersion: nais.io/v1alpha1
kind: Application
metadata:
name: <MY-APP>
...
spec:
...
gcp:
buckets:
- name: <MY-BUCKET>
retentionPeriodDays: 30
lifecycleCondition:
age: 7
createdBefore: 2020-01-01
daysSinceCustomTime: 2
numNewerVersions: 2
withState: ANYretentionPeriodDays and lifecycleCondition are for necessary for backup.
Deploy your manifest ΒΆ
Deploy your manifest either using Nais deploy action, or manually:
bash
kubectl apply -f <PATH-TO-MANIFEST>