Skip to content

Commit 58e78f1

Browse files
committed
feat(mysql): allow binary paths overriding
https://www.wrike.com/open.htm?id=1632501983
1 parent 027dac2 commit 58e78f1

File tree

5 files changed

+7
-4
lines changed

5 files changed

+7
-4
lines changed

defaults/main.yml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,9 @@ db_pull_skip_restore: false
2424
db_pull_exclude_table: []
2525
db_pull_exclude_table_data: []
2626

27+
db_pull_mysql_mysql_binary_path: mysql
28+
db_pull_mysql_mysqldump_binary_path: mysqldump
29+
2730
db_pull_postgresql_createdb_binary_path: createdb
2831
db_pull_postgresql_dropdb_binary_path: dropdb
2932
db_pull_postgresql_pg_dump_binary_path: pg_dump

tasks/mysql/create.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
delegate_to: localhost
33
become: false
44
shell: >
5-
mysql \
5+
{{ db_pull_mysql_mysql_binary_path }} \
66
-u {{ db_pull_local_database_user }} \
77
--password={{ db_pull_local_database_password }} \
88
-h {{ db_pull_local_database_host }} \

tasks/mysql/drop.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
delegate_to: localhost
33
become: false
44
shell: >
5-
mysql \
5+
{{ db_pull_mysql_mysql_binary_path }} \
66
-u {{ db_pull_local_database_user }} \
77
--password={{ db_pull_local_database_password }} \
88
-h {{ db_pull_local_database_host }} \

tasks/mysql/dump.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
- name: backup mysql db server
22
shell: >
3-
mysqldump \
3+
{{ db_pull_mysql_mysqldump_binary_path }} \
44
-u {{ db_pull_remote_database_user }} \
55
--password={{ db_pull_remote_database_password }} \
66
{{ ['--ignore-table']|product(db_pull_exclude_table)|map('join', ' ')|join(' ') }} \

tasks/mysql/restore.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
delegate_to: localhost
33
become: false
44
shell: >
5-
mysql \
5+
{{ db_pull_mysql_mysql_binary_path }} \
66
-u {{ db_pull_local_database_user }} \
77
--password={{ db_pull_local_database_password }} \
88
-h {{ db_pull_local_database_host }} \

0 commit comments

Comments
 (0)