Skip to content

Instantly share code, notes, and snippets.

@gravyboat
Created July 28, 2014 18:00
Show Gist options
  • Save gravyboat/5b62a6e91d6994fffb4a to your computer and use it in GitHub Desktop.
Save gravyboat/5b62a6e91d6994fffb4a to your computer and use it in GitHub Desktop.
file.absent
/etc/mysql/my.cnf:
file.managed:
- source: salt://database/config_files/master/my.cnf
- user: root
- group: root
- mode: 644
- template: jinja
- defaults:
innodb_buffer_pool_size: {{ pillar.db_config.innodb_buffer_pool_size }}
join_buffer_size: {{ pillar.db_config.join_buffer_size }}
query_cache_limit: {{ pillar.db_config.query_cache_limit }}
remove_logfile0:
file.absent:
- name: /var/lib/mysql/ib_logfile0
remove_logfile1:
file.absent:
- name: /var/lib/mysql/ib_logfile1
@gravyboat
Copy link
Author

/etc/mysql/my.cnf:
  file.managed:
    - source: salt://database/config_files/master/my.cnf
    - user: root
    - group: root
    - mode: 644
    - template: jinja
    - defaults:
        innodb_buffer_pool_size: {{ pillar.db_config.innodb_buffer_pool_size }}
        join_buffer_size: {{ pillar.db_config.join_buffer_size }}
        query_cache_limit: {{ pillar.db_config.query_cache_limit }}

remove_logfile0:
  file.absent:
    - name: /var/lib/mysql/ib_logfile0
    - watch:
      - file: /etc/mysql/my.cnf
remove_logfile1:
  file.absent:
    - name: /var/lib/mysql/ib_logfile1
    - watch:
      - file: /etc/mysql/my.cnf

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