Skip to content

Commit 76de3bb

Browse files
committed
Updated readme
1 parent 2ae51be commit 76de3bb

File tree

1 file changed

+81
-16
lines changed

1 file changed

+81
-16
lines changed

README.md

Lines changed: 81 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,30 +1,95 @@
1-
![build-status](https://travis-ci.com/theonestack/hl-component-aurora-postgres.svg?branch=master)
1+
# aurora (Postgres) CfHighlander component
2+
## Parameters
23

3-
### Cfhighlander Aurora Postgres component
4+
| Name | Use | Default | Global | Type | Allowed Values |
5+
| ---- | --- | ------- | ------ | ---- | -------------- |
6+
| EnvironmentName | Tagging | dev | true | string
7+
| EnvironmentType | Tagging | development | true | string | ['development','production']
8+
| VPCId | Security Groups | None | false | AWS::EC2::VPC::Id
9+
| DnsDomain | DNS domain to use | None | true | string
10+
| SubnetIds | List of subnets | None | false | CommaDelimitedList
11+
| KmsKeyId | KMS ID | None | false | string (arn)
12+
| NamespaceId | Service discovery namespace ID | None | false | string
13+
| SnapshotId | Snapshot ID to provision from | None | false | string
14+
| WriterInstanceType | Writer instance type *if engine is set to provisioned* | None | false | string
15+
| ReaderInstanceType | Reader instance type *if engine is set to provisioned* | None | false | string
16+
## Outputs/Exports
417

5-
```bash
18+
| Name | Value | Exported |
19+
| ---- | ----- | -------- |
20+
| SecurityGroup | Security Group name | true
21+
| ServiceRegistry | CloudMap service registry ID | true
22+
| DBClusterId | Database Cluster ID | true
23+
24+
## Included Components
625

7-
# install highlander gem
8-
$ gem install cfhighlander
26+
[lib-ec2](https://github.com/theonestack/hl-component-lib-ec2)
927

10-
# build and validate standalone component
11-
$ cfcompile --validate
28+
## Example Configuration
29+
### Highlander
30+
```
31+
Component name:'database', template: 'aurora-postgres' do
32+
parameter name: 'DnsDomain', value: root_domain
33+
parameter name: 'DnsFormat', value: FnSub("${EnvironmentName}.#{root_domain}")
34+
parameter name: 'SubnetIds', value: cfout('vpcv2', 'PersistenceSubnets')
35+
parameter name: 'WriterInstanceType', value: writer_instance
36+
parameter name: 'ReaderInstanceType', value: reader_instance
37+
parameter name: 'EnableReader', value: 'true'
38+
parameter name: 'StackOctet', value: '80'
39+
parameter name: 'NamespaceId', value: cfout('servicediscovery', 'NamespaceId')
40+
end
41+
```
1242

43+
### Aurora Postgres Configuration
1344
```
14-
### Usage
45+
hostname: db
46+
database_name: appdb
47+
dns_format: ${DnsFormat}
48+
49+
storage_encrypted: true
50+
engine: aurora-postgres
51+
engine_version: '13.4'
52+
53+
writer_instance: db.r3.large
54+
reader_instance: db.r3.large
55+
56+
master_login:
57+
username_ssm_param: /${EnvironmentName}/myapp/dbuser
58+
password_ssm_param: /${EnvironmentName}/myapp/dbpass
1559
16-
### Configuration options
60+
security_group:
61+
-
62+
rules:
63+
-
64+
IpProtocol: tcp
65+
FromPort: 5432
66+
ToPort: 5432
67+
ips:
68+
- stack
69+
- company_office
70+
- company_client_vpn
1771
18-
TBD
72+
service_discovery:
73+
name: db
74+
```
1975

20-
### Parameters
76+
## Cfhighlander Setup
2177

22-
TBD
78+
install cfhighlander [gem](https://github.com/theonestack/cfhighlander)
2379

24-
### Configuration options
80+
```bash
81+
gem install cfhighlander
82+
```
2583

26-
TBD
84+
or via docker
2785

28-
### Outputs
86+
```bash
87+
docker pull theonestack/cfhighlander
88+
```
89+
## Testing Components
90+
91+
Running the tests
2992

30-
TBD
93+
```bash
94+
cfhighlander cftest aurora-postgres
95+
```

0 commit comments

Comments
 (0)