Skip to content

Commit

Permalink
simplify the depdencies, as well as get it right
Browse files Browse the repository at this point in the history
grant must also be finished and everything else comes before grant
so we can reduce the lookups to just the grant
  • Loading branch information
duritong committed Jun 26, 2016
1 parent 3021017 commit 5ab2bbb
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions manifests/instance.pp
Original file line number Diff line number Diff line change
Expand Up @@ -92,11 +92,11 @@
subscribe => Exec["install_wordpress_${name}"],
before => Service['apache'];
}
# make sure we get the local relations right
if $install_options['dbhost'] in ['localhost','127.0.0.1','::1'] {
# make sure we have the local grants done before installing wp
$dbhost = $install_options['dbhost']
if $dbhost in ['localhost','127.0.0.1','::1'] {
$dbname = $install_options['dbname']
Mysql_database<| title == $dbname |> -> Exec["config_wordpress_${name}"]
Mysql_user<| title == $dbuser |> -> Exec["config_wordpress_${name}"]
Mysql_grant<| title == "${dbuser}@${dbhost}/${dbname}" |> -> Exec["config_wordpress_${name}"]
}

$installed_plugins = suffix(union($install_options['installed_plugins'],
Expand Down

0 comments on commit 5ab2bbb

Please sign in to comment.