gogs-mysql.yml 371 B

123456789101112131415161718
  1. ---
  2. - name: Create Gogs MySQL user.
  3. mysql_user: >
  4. name={{ gogs_db_username }}
  5. host={{ item }}
  6. priv={{ gogs_db_name }}.*:ALL
  7. password={{ gogs_db_password }}
  8. with_items:
  9. - 127.0.0.1
  10. - ::1
  11. - localhost
  12. when: gogs_use_mysql
  13. - name: Create Gogs MySQL database.
  14. mysql_db: >
  15. db={{ gogs_db_name }}
  16. state=present
  17. when: gogs_use_mysql