Skip to content

Allow wildcard host assignment with sql. #68

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 4, 2012
Merged

Allow wildcard host assignment with sql. #68

merged 1 commit into from
May 4, 2012

Conversation

razorsedge
Copy link
Contributor

Since mysql:db requires class mysql::server, we assume to run all commands as the root mysql user against the local mysql server. Therefore, Exec["${name}-import"] can be simplified and will also succeed with the following wildcard host assignment:

mysql::db { 'mydb':
  user     => 'myuser',
  password => 'mypass',
  host     => '%',
  grant    => ['all'],
  sql      => '/path/to/file.sql',
}

This time with no formatting "fixes".

Show that mysql:db can also import SQL from a file in order to, for
example, initialize a database schema.  Since it requires class
mysql::server, we assume to run all commands as the root mysql user
against the local mysql server.
nanliu added a commit that referenced this pull request May 4, 2012
Allow wildcard host assignment with sql.
@nanliu nanliu merged commit 22f59f0 into puppetlabs:master May 4, 2012
pmcmaw pushed a commit to pmcmaw/puppetlabs-mysql that referenced this pull request Mar 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants