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

simplify mysql slurm user creation #54

Open
martbhell opened this issue Jul 8, 2016 · 0 comments
Open

simplify mysql slurm user creation #54

martbhell opened this issue Jul 8, 2016 · 0 comments

Comments

@martbhell
Copy link
Contributor

https://github.com/CSC-IT-Center-for-Science/ansible-role-slurm/blob/master/tasks/dbd.yml#L74

has

 - name: check if slurm db user exists
    mysql_user: "name=slurm state=present"
    register: mysqlslurmuser
    ignore_errors: yes
    tags: debug

And then later we:

  - name: create slurm db user if it does not exist
    mysql_user: "name=slurm password={{ slurm_mysql_password }} priv=slurm_acct_db.*:ALL state=present update_password=always"
    when: mysqlslurmuser|failed or mysqlslurmuser|changed

Could we remove the first one (which creates the sql user) and run the mysql_user module/task just once?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant