You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
604 B
YAML
28 lines
604 B
YAML
12 months ago
|
apiVersion: stackgres.io/v1
|
||
|
kind: SGScript
|
||
|
metadata:
|
||
|
namespace: sharkey
|
||
|
name: cluster-scripts
|
||
|
spec:
|
||
|
continueOnError: true
|
||
|
scripts:
|
||
|
- name: create-user
|
||
|
retryOnError: true
|
||
|
version: 1
|
||
|
scriptFrom:
|
||
|
secretKeyRef:
|
||
|
name: sharkey-secret
|
||
|
key: create-user.sql
|
||
|
- name: create-db
|
||
|
version: 1
|
||
|
script: |
|
||
|
CREATE DATABASE sharkey;
|
||
|
- name: grant-permissions
|
||
|
retryOnError: true
|
||
|
version: 1
|
||
|
script: |
|
||
|
GRANT ALL ON DATABASE sharkey TO sharkey;
|
||
|
ALTER DATABASE sharkey OWNER TO sharkey;
|
||
|
GRANT USAGE, CREATE ON SCHEMA public TO sharkey;
|
||
|
|