Open AWS Console
In the AWS Console, Navigate to Services > Database, RDS
In the RDS screen, click on Databases, then click on Create Database.
In Choose a database creation method select Standard Create. And then, in Engine options use the settings:
In Templates select Dev/Test
We are using Dev/Test selection on this exercise because there are no active users running the application. For a production environment prefer the Production template.
In Settings use the following settings:
In DB Instance size select Burstable classes. Change the size to db.t3.medium and, in Availability & durability select Don’t create an Aurora Replica
In Connectivity change the following settings:
In Database authentication select Password authentication. And then, expand Additional configuration
Still in Additional configuration
Click on Create database
Wait until the Available status for the Aurora ofbiz database:
Click on mid-ofbiz-instance-1 Writer database and write down the endpoint. Keep it, we will use it during this lab.
From your BASTION host, open putty:
Connect to the server ofbiz-db. For EventEngine event, the username and password are in your EventEngine dashboard. If you are running this lab in your own AWS account, the username is user and the password will be the same that you defined during the CloudFormation launch.
Connect to the Aurora Postgres server. Replace <INSERT AURORA DNS VALUE FROM STEP 12> before running the command.
sudo psql postgres --username=ofbiz -h <INSERT AURORA DNS VALUE FROM STEP 12>
Now, let’s create the databases ofbiz, ofbizolap and ofbiztenant. We will also grant privileges to the user ofbiz to all databases. Run the following command (using the same password that you specified on step 6 to connect to your Aurora Postgres database. Once connected run the following commands:
CREATE DATABASE ofbiz; GRANT ALL PRIVILEGES ON DATABASE ofbiz TO ofbiz; CREATE DATABASE ofbizolap; GRANT ALL PRIVILEGES ON DATABASE ofbizolap TO ofbiz; CREATE DATABASE ofbiztenant; GRANT ALL PRIVILEGES ON DATABASE ofbiztenant TO ofbiz; \q
HINT: Use a text editor to arrange the commands before past it into the putty