aboutsummaryrefslogtreecommitdiffstats
path: root/mysql.yaml
diff options
context:
space:
mode:
authorClint Byrum <clint@fewbar.com>2013-03-21 20:44:50 +0000
committerClint Byrum <clint@fewbar.com>2013-03-21 20:44:50 +0000
commit5cbb8d3a852d6360c3935d183e85ccb74e283ec6 (patch)
treea2f85adc5f48adf8025d68e424344cb4b707b709 /mysql.yaml
parentebbfa0a7ee541c636b86eca14cc0d0adfe9fed69 (diff)
Adding functionality to mysql
Diffstat (limited to 'mysql.yaml')
-rw-r--r--mysql.yaml47
1 files changed, 41 insertions, 6 deletions
diff --git a/mysql.yaml b/mysql.yaml
index 722cff87..f8d92627 100644
--- a/mysql.yaml
+++ b/mysql.yaml
@@ -9,14 +9,30 @@ Parameters:
Description: Use this flavor
Type: String
Default: bm.small
+ KeystoneUser:
+ Description: Keystone database username.
+ Type: String
+ Default: keystone
MySQLImage:
Type: String
- BootstrapUrl:
- Description: Fetch a mysql dump file from this URL and load it
+ BootstrapHost:
+ Description: Load mysqldump from this Host
+ Type: String
+ Default: ''
+ BootstrapRootPassword:
+ Description: Root password for localhost access after bootstrap
+ Type: String
+ Default: ''
+ BootstrapDumpPassword:
+ Description: Password to use for mysqldump from Bootstrap Host
+ Type: String
+ Default: ''
+ BootstrapSlaveUser:
+ Description: User to use for replication from bootstrap host
Type: String
Default: ''
- BootstrapRootCnfUrl:
- Description: Fetch a mysql config file from this URL to setup local root with bootstrapped database
+ BootstrapSlavePassword:
+ Description: Password to use with BootstrapSlaveUser
Type: String
Default: ''
Resources:
@@ -40,9 +56,17 @@ Resources:
OpenStack::Config:
mysql:
users:
+ root:
+ password: {Ref: BootstrapRootPassword}
+ dump:
+ password: {Ref: BootstrapDumpPassword}
+ create-users:
- database: keystone
- bootstrap_url: {Ref: BootstrapUrl}
- root_cnf_url: {Ref: BootstrapRootCnfUrl}
+ username: {Ref: KeystoneUser}
+ userhandle: {Ref: KeystonePasswordHandle}
+ bootstrap_host: {Ref: BootstrapHost}
+ slave_user: {Ref: BootstrapSlaveUser}
+ slave_password: {Ref: BootstrapSlavePassword}
heat:
access_key_id:
Ref: ApiKey
@@ -59,6 +83,17 @@ Resources:
InstanceType: {Ref: InstanceType}
KeyName: {Ref: KeyName}
UserData: "#!/bin/bash\ntouch /tmp/userdata-finished\necho Userdata finished $(date)\n"
+ KeystonePasswordHandle:
+ Type: AWS::CloudFormation::WaitConditionHandle
+ KeystonePassword:
+ DependsOn: MySQL
+ Type: AWS::CloudFormation::WaitCondition
+ Properties:
+ Handle: {Ref: KeystonePasswordHandle}
+ Timeout: 60
Outputs:
MySQLHost:
Fn::GetAtt: [ MySQL , PrivateIp ]
+ KeystonePassword:
+ Fn::GetAtt: [ KeystonePassword, Data ]
+ KeystoneUser: {Ref: KeystoneUser}