Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
use config file settings to configure database
Let the database configuration scripts get the configuration parameter from the director config file. Now, the scripts try to get there values in following order: 1. environment variable (db_name, db_user, db_password) 2. director config file 3. fallback value (from configure) Signed-off-by: Marco van Wieringen <marco.van.wieringen@bareos.com>
- Loading branch information
1 parent
a686d2c
commit d985475
Showing
10 changed files
with
98 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
USE mysql | ||
-- read-only access for third party applications | ||
GRANT SELECT ON TABLE @DB_NAME@.* TO @DB_USER@@localhost @DB_PASS@; | ||
GRANT SELECT ON TABLE @DB_NAME@.* TO @DB_USER@@"%" @DB_PASS@; | ||
GRANT SELECT ON TABLE @DB_NAME@.* TO @DB_USER@@'127.0.0.1' @DB_PASS@; | ||
GRANT SELECT ON TABLE @DB_NAME@.* TO @DB_USER@@'::1' @DB_PASS@; | ||
FLUSH PRIVILEGES; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
USE mysql | ||
GRANT ALL PRIVILEGES ON @DB_NAME@.* TO @DB_USER@@localhost @DB_PASS@; | ||
GRANT ALL PRIVILEGES ON @DB_NAME@.* TO @DB_USER@@"%" @DB_PASS@; | ||
GRANT ALL PRIVILEGES ON TABLE @DB_NAME@.* TO @DB_USER@@localhost @DB_PASS@; | ||
GRANT ALL PRIVILEGES ON TABLE @DB_NAME@.* TO @DB_USER@@'127.0.0.1' @DB_PASS@; | ||
GRANT ALL PRIVILEGES ON TABLE @DB_NAME@.* TO @DB_USER@@'::1' @DB_PASS@; | ||
FLUSH PRIVILEGES; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters