File tree Expand file tree Collapse file tree 1 file changed +24
-2
lines changed Expand file tree Collapse file tree 1 file changed +24
-2
lines changed Original file line number Diff line number Diff line change 12
12
[ ![ codecov] ( https://codecov.io/gh/techouse/mysql-to-sqlite3/branch/master/graph/badge.svg )] ( https://codecov.io/gh/techouse/mysql-to-sqlite3 )
13
13
[ ![ GitHub stars] ( https://img.shields.io/github/stars/techouse/mysql-to-sqlite3.svg?style=social&label=Star&maxAge=2592000 )] ( https://github.com/techouse/mysql-to-sqlite3/stargazers )
14
14
15
-
16
15
# MySQL to SQLite3
17
16
18
17
#### A simple Python tool to transfer data from MySQL to SQLite 3.
@@ -25,6 +24,7 @@ mysql2sqlite --help
25
24
```
26
25
27
26
### Usage
27
+
28
28
```
29
29
Usage: mysql2sqlite [OPTIONS]
30
30
@@ -83,4 +83,26 @@ Options:
83
83
--debug Debug mode. Will throw exceptions.
84
84
--version Show the version and exit.
85
85
--help Show this message and exit.
86
- ```
86
+ ```
87
+
88
+ #### Docker image usage
89
+
90
+ If you don't want to install the tool on your system, you can use the Docker image instead.
91
+
92
+ ``` bash
93
+ docker run -it \
94
+ --workdir $( pwd) \
95
+ --volume $( pwd) :$( pwd) \
96
+ --rm ghcr.io/techouse/mysql-to-sqlite3:latest \
97
+ --sqlite-file baz.db \
98
+ --mysql-user foo \
99
+ --mysql-password bar \
100
+ --mysql-database baz \
101
+ --mysql-host host.docker.internal
102
+ ```
103
+
104
+ This will mount your host current working directory (pwd) inside the Docker container as the current working directory.
105
+ Any files Docker would write to the current working directory are written to the host directory where you did docker
106
+ run. Note that you have to also use a
107
+ [ special hostname] ( https://docs.docker.com/desktop/networking/#use-cases-and-workarounds-for-all-platforms ) ` host.docker.internal `
108
+ to access your host machine from inside the Docker container.
You can’t perform that action at this time.
0 commit comments