Skip to content

Commit 86f22f5

Browse files
Merge pull request #34 from abhisbyk/AbhiK_sidb_yaml_fixes
Sample SIDB YAML file changes
2 parents d4ef512 + 5c4917a commit 86f22f5

8 files changed

+104
-80
lines changed

config/samples/sidb/oraclerestdataservice_apex.yaml

Lines changed: 0 additions & 29 deletions
Original file line numberDiff line numberDiff line change
@@ -3,35 +3,6 @@
33
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
44
#
55

6-
apiVersion: v1
7-
kind: Secret
8-
metadata:
9-
name: ords-secret
10-
namespace: default
11-
type: Opaque
12-
stringData:
13-
## Specify your ORDS password here
14-
oracle_pwd:
15-
16-
---
17-
18-
apiVersion: v1
19-
kind: Secret
20-
metadata:
21-
name: apex-secret
22-
namespace: default
23-
type: Opaque
24-
stringData:
25-
## Specify your APEX password here
26-
## This password should complete the following requirements:
27-
## 1. Contain at least 6 characters.
28-
## 2. Contain at least one numeric character (0123456789).
29-
## 3. Contain at least one punctuation character (!"#$%&()``*+,-/:;?_).
30-
## 4. Contain at least one uppercase alphabetic character.
31-
oracle_pwd:
32-
33-
---
34-
356
apiVersion: database.oracle.com/v1alpha1
367
kind: OracleRestDataService
378
metadata:

config/samples/sidb/oraclerestdataservice_create.yaml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,6 @@
33
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
44
#
55

6-
apiVersion: v1
7-
kind: Secret
8-
metadata:
9-
name: ords-secret
10-
namespace: default
11-
type: Opaque
12-
stringData:
13-
## Specify your ORDS password here
14-
oracle_pwd:
15-
16-
---
17-
186
apiVersion: database.oracle.com/v1alpha1
197
kind: OracleRestDataService
208
metadata:
Lines changed: 33 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,33 @@
1+
#
2+
# Copyright (c) 2022, Oracle and/or its affiliates. All rights reserved.
3+
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
4+
#
5+
6+
## ORDS password secret
7+
apiVersion: v1
8+
kind: Secret
9+
metadata:
10+
name: ords-secret
11+
namespace: default
12+
type: Opaque
13+
stringData:
14+
## Specify your ORDS password here
15+
oracle_pwd:
16+
17+
---
18+
19+
## APEX password secret
20+
apiVersion: v1
21+
kind: Secret
22+
metadata:
23+
name: apex-secret
24+
namespace: default
25+
type: Opaque
26+
stringData:
27+
## Specify your APEX password here
28+
## This password should complete the following requirements:
29+
## 1. Contain at least 6 characters.
30+
## 2. Contain at least one numeric character (0123456789).
31+
## 3. Contain at least one punctuation character (!"#$%&()``*+,-/:;?_).
32+
## 4. Contain at least one uppercase alphabetic character.
33+
oracle_pwd:

config/samples/sidb/singleinstancedatabase_create.yaml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,6 @@
33
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
44
#
55

6-
apiVersion: v1
7-
kind: Secret
8-
metadata:
9-
name: db-admin-secret
10-
namespace: default
11-
type: Opaque
12-
stringData:
13-
# Specify your DB password here
14-
oracle_pwd:
15-
16-
---
17-
186
apiVersion: database.oracle.com/v1alpha1
197
kind: SingleInstanceDatabase
208
metadata:

config/samples/sidb/singleinstancedatabase_express.yaml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,6 @@
33
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
44
#
55

6-
apiVersion: v1
7-
kind: Secret
8-
metadata:
9-
name: xedb-admin-secret
10-
namespace: default
11-
type: Opaque
12-
stringData:
13-
## Specify your DB password here
14-
oracle_pwd:
15-
16-
---
17-
186
apiVersion: database.oracle.com/v1alpha1
197
kind: SingleInstanceDatabase
208
metadata:

config/samples/sidb/singleinstancedatabase_prebuiltdb.yaml

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -3,18 +3,6 @@
33
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
44
#
55

6-
apiVersion: v1
7-
kind: Secret
8-
metadata:
9-
name: prebuiltdb-admin-secret
10-
namespace: default
11-
type: Opaque
12-
stringData:
13-
## Specify your DB password here
14-
oracle_pwd:
15-
16-
---
17-
186
apiVersion: database.oracle.com/v1alpha1
197
kind: SingleInstanceDatabase
208
metadata:
Lines changed: 41 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,41 @@
1+
#
2+
# Copyright (c) 2022, Oracle and/or its affiliates.
3+
# Licensed under the Universal Permissive License v 1.0 as shown at http://oss.oracle.com/licenses/upl.
4+
#
5+
6+
## Database Admin Password Secret
7+
apiVersion: v1
8+
kind: Secret
9+
metadata:
10+
name: db-admin-secret
11+
namespace: default
12+
type: Opaque
13+
stringData:
14+
## Specify your DB password here
15+
oracle_pwd:
16+
17+
---
18+
19+
## Oracle Database XE Admin password secret
20+
apiVersion: v1
21+
kind: Secret
22+
metadata:
23+
name: prebuiltdb-admin-secret
24+
namespace: default
25+
type: Opaque
26+
stringData:
27+
## Specify your DB password here
28+
oracle_pwd:
29+
30+
---
31+
32+
## Prebuilt-Database Admin password secret
33+
apiVersion: v1
34+
kind: Secret
35+
metadata:
36+
name: xedb-admin-secret
37+
namespace: default
38+
type: Opaque
39+
stringData:
40+
## Specify your DB password here
41+
oracle_pwd:

docs/sidb/README.md

Lines changed: 30 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,9 +135,9 @@ The `adminPassword` field in the above `singleinstancedatabase.yaml` file refers
135135

136136
Create this secret using the following command as an example:
137137

138-
kubectl create secret generic admin-secret --from-literal=oracle_pwd=<specify password here>
138+
kubectl create secret generic db-admin-secret --from-literal=oracle_pwd=<specify password here>
139139

140-
This command creates a secret named `admin-secret`, with the key `oracle_pwd` mapped to the actual password specified in the command.
140+
This command creates a secret named `db-admin-secret`, with the key `oracle_pwd` mapped to the actual password specified in the command.
141141

142142
### Create a Database
143143

@@ -199,6 +199,13 @@ This command pulls the XE image uploaded on the [Oracle Container Registry](http
199199
- For XE database, only single replica mode (i.e. `replicas: 1`) is supported.
200200
- For XE database, you **cannot change** the init parameters i.e. `cpuCount, processes, sgaTarget or pgaAggregateTarget`.
201201
202+
#### Additional Information
203+
You are required to specify the database admin password secret in the corresponding YAML file. The default values mentioned in the `adminPassword.secretName` fields of [singleinstancedatabase_create.yaml](../../config/samples/sidb/singleinstancedatabase_create.yaml), [singleinstancedatabase_prebuiltdb.yaml](../../config/samples/sidb/singleinstancedatabase_prebuiltdb.yaml) and [singleinstancedatabase_express.yaml](../../config/samples/sidb/singleinstancedatabase_express.yaml) files are `db-admin-secret`, `prebuiltdb-admin-secret`, and `xedb-admin-secret` respectively. You can create these secrets manually by using the sample command mentioned in the [Template YAML](#template-yaml) section. Alternatively, you can create these secrets by filling the passwords in the **[singleinstancedatabase_secrets.yaml](../../config/samples/sidb/singleinstancedatabase_secrets.yaml)** file and applying it using the command below:
204+
205+
```bash
206+
kubectl apply -f singleinstancedatabase_secrets.yaml
207+
```
208+
202209
### Connecting to Database
203210
204211
Creating a new database instance takes a while. When the `status` column returns the response `Healthy`, the Database is open for connections.
@@ -588,6 +595,20 @@ $ kubectl apply -f oraclerestdataservice_create.yaml
588595
```
589596
After this command completes, ORDS is installed in the container database (CDB) of the Single Instance Database.
590597

598+
##### NOTE:
599+
You are required to specify the ORDS secret in the [oraclerestdataservice_create.yaml](../../config/samples/sidb/oraclerestdataservice_create.yaml) file. The default value mentioned in the `adminPassword.secretName` field is `ords-secret`. You can create this secret manually by using the following command:
600+
601+
```bash
602+
kubectl create secret generic ords-secret --from-literal=oracle_pwd=<specify password here>
603+
```
604+
605+
Alternatively, you can create this secret and the APEX secret by filling the passwords in the **[oraclerestdataservice_secrets.yaml](../../config/samples/sidb/oraclerestdataservice_secrets.yaml)** file and applying it using the command below:
606+
607+
```bash
608+
kubectl apply -f singleinstancedatabase_secrets.yaml
609+
```
610+
The APEX secret created above, will be used while [installing APEX](#apex-installation).
611+
591612
#### Creation Status
592613

593614
Creating a new ORDS instance takes a while. To check the status of the ORDS instance, use the following command:
@@ -744,7 +765,13 @@ The `OraOperator` facilitates installation of APEX in the database and also conf
744765
745766
kubectl apply -f oraclerestdataservice_apex.yaml
746767
747-
* The APEX Password is used as a common password for `APEX_PUBLIC_USER, APEX_REST_PUBLIC_USER, APEX_LISTENER` and Apex administrator (username: `ADMIN`) mapped to secretKey.
768+
* The APEX Password is used as a common password for `APEX_PUBLIC_USER, APEX_REST_PUBLIC_USER, APEX_LISTENER` and Apex administrator (username: `ADMIN`) mapped to secretKey. You can create APEX secret using the following command:
769+
770+
```bash
771+
kubectl create secret generic apex-secret --from-literal=oracle_pwd=<specify password here>
772+
```
773+
Please refer [this](#note) section for APEX secret creation using the **[oraclerestdataservice_secrets.yaml](../../config/samples/sidb/oraclerestdataservice_secrets.yaml)** file.
774+
748775
* The status of ORDS turns to `Updating` during APEX configuration, and changes to `Healthy` after successful configuration. You can also check status by using the following command:
749776
750777

0 commit comments

Comments
 (0)