Skip to content

Commit

Permalink
Closes-Bug: #1602872 - User configured database dir not created if pa…
Browse files Browse the repository at this point in the history
…th doesn't exist

for example: if user gives /var/lib/cassandra/data as database_dir, it won't be created as /var/lib/cassandra dir doesn't exist

Change-Id: I346d0b2c20c549e368ebff52008297be9a5ca588
  • Loading branch information
nitishkrishna committed Sep 27, 2016
1 parent 2cab8b8 commit 3c14eb8
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -93,6 +93,12 @@
notify { "Database - zookeeper_ip_list = ${zookeeper_ip_list}":;} ->
notify { "Database - database_index = ${database_index}":;} ->
notify { "Database - cassandra_seeds = ${cassandra_seeds}":;} ->
exec {'Create database dir':
command => "mkdir -p ${database_dir}",
unless => "test -d ${database_dir}",
provider => shell,
logoutput => $contrail_logoutput
} ->
file { $database_dir :
ensure => directory,
owner => cassandra,
Expand Down

0 comments on commit 3c14eb8

Please sign in to comment.