aboutsummaryrefslogtreecommitdiffstats
path: root/modules/postgresql/manifests/remote_db_and_user.pp
blob: eedeaa1773c4f7461e42dae4a487008677410b72 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
# FIXME: In puppet >3.0 word 'tag' is reserved, so it have to be renamed
define postgresql::remote_db_and_user($password,
                                      $description = '',
                                      $tag = 'default',
                                      $callback_notify = '') {

    @@postgresql::db_and_user { $name:
        callback_notify => $callback_notify,
        tag             => $tag,
        description     => $description,
        password        => $password,
    }

    # fetch the exported ressources that should have been exported
    # once the db was created, and trigger a notify to the object
    # passed as callback_notify
    Postgresql::Database_callback <<| tag == $name |>>
}