Skip to content
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

Update replicate_db.j2 #336

Closed

Conversation

zhuatuzilo
Copy link

add auto create db if not exists

add auto create db if not exists
@spetrosi
Copy link
Collaborator

I think this may cause troubles. E.g. if users do a typo in a database name in mssql_ha_db_names, the role will create and replicate an extra database.

README suggests to use mssql_pre_input_sql_file to pre-create a database if it doesn't exist. See https://github.com/linux-system-roles/mssql/blob/main/README.md?plain=1#L697-L700

The role should fail with an informative error message if a database provided in mssql_ha_db_names does not exist, saying that the database with this name doesn't exist and that you can create it e.g. with mssql_pre_input_sql_file.

@zhuatuzilo
Copy link
Author

you are right,maybe it's just my personal need,and i will change this in my local

@zhuatuzilo zhuatuzilo closed this Feb 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants