node-dev-vagrant-example
node-dev-vagrant-example copied to clipboard
Invalid requisite type
I'm receiving the following error: Invalid requisite type 'mysql_user.present' in state 'dbconfig', in SLS 'mysql'. Requisite types must not contain dots, did you mean 'mysql_user'?
When I try mysql_user it says the function is not defined. Any ideas?
Ok, I figured it out.
You need to remove the .present beneath the required keys. For example:
dbconfig:
mysql_user.present:
- name: vagruser
- password: devman
- require:
- service: mysql
- pkg: python-mysqldb
mysql_database.present:
- name: workoutbot
- require:
- mysql_user: dbconfig
mysql_grants.present:
- grant: all privileges
- database: workoutbot.*
- user: vagruser
- require:
- mysql_database: dbconfig