You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Oct 29, 2023. It is now read-only.
NEW FEATURES
- Implemented Issue 21 "Add support for directly using path to binaries"
BUGS FIXED
- unpack would not act on old tarball where files were not
explicitly marked as regular.
TESTING
- Added test for Issue 21
Copy file name to clipboardExpand all lines: README.md
+58-11
Original file line number
Diff line number
Diff line change
@@ -3,7 +3,7 @@
3
3
[DBdeployer](https://github.com/datacharmer/dbdeployer) is a tool that deploys MySQL database servers easily.
4
4
This is a port of [MySQL-Sandbox](https://github.com/datacharmer/mysql-sandbox), originally written in Perl, and re-designed from the ground up in [Go](https://golang.org). See the [features comparison](https://github.com/datacharmer/dbdeployer/blob/master/docs/features.md) for more detail.
5
5
6
-
Documentation updated for version 1.7.0 (30-Jun-2018 20:44 UTC)
6
+
Documentation updated for version 1.8.0 (08-Jul-2018 08:03 UTC)
7
7
8
8
## Installation
9
9
@@ -13,7 +13,7 @@ Get the one for your O.S. from [dbdeployer releases](https://github.com/datachar
The program doesn't have any dependencies. Everything is included in the binary. Calling *dbdeployer* without arguments or with ``--help`` will show the main help screen.
48
48
49
49
$ dbdeployer --version
50
-
dbdeployer version 1.7.0
50
+
dbdeployer version 1.8.0
51
51
52
52
53
53
$ dbdeployer -h
@@ -179,6 +179,7 @@ The easiest command is ``deploy single``, which installs a single sandbox.
179
179
For example:
180
180
dbdeployer deploy single 5.7 # deploys the latest release of 5.7.x
181
181
dbdeployer deploy single 5.7.21 # deploys a specific release
182
+
dbdeployer deploy single /path/to/5.7.21 # deploys a specific release in a given path
182
183
183
184
For this command to work, there must be a directory $HOME/opt/mysql/5.7.21, containing
184
185
the binary files from mysql-5.7.21-$YOUR_OS-x86_64.tar.gz
@@ -233,6 +234,7 @@ The ``deploy replication`` command will install a master and two or more slaves,
@@ -293,17 +295,62 @@ You can issue the command ``dbdeployer deploy single 8.0``, and it will use 8.0.
293
295
294
296
## Multiple sandboxes, same version and type
295
297
296
-
If you want to deploy several instances of the same version and the same type (for example two single sandboxes of 8.0.4, or two group replication instances with different single-primary setting) you can specify the data directory name and the ports manually.
298
+
If you want to deploy several instances of the same version and the same type (for example two single sandboxes of 8.0.4, or two replication instances with different settings) you can specify the data directory name and the ports manually.
297
299
298
300
$ dbdeployer deploy single 8.0.4
299
301
# will deploy in msb_8_0_4 using port 8004
300
302
301
303
$ dbdeployer deploy single 8.0.4 --sandbox-directory=msb2_8_0_4
302
304
# will deploy in msb2_8_0_4 using port 8005 (which dbdeployer detects and uses)
# will deploy replication in rsandbox_8_0_4 using default calculated ports 19009, 19010, 19011
308
+
309
+
$ dbdeployer deploy replication 8.0.4 \
310
+
--gtid \
311
+
--sandbox-directory=rsandbox2_8_0_4 \
312
+
--base-port=18600 --concurrent
305
313
# will deploy replication in rsandbox2_8_0_4 using ports 18601, 18602, 18603
306
314
315
+
## Using the direct path to the expanded tarball
316
+
317
+
If you have a custom organization of expanded tarballs, you may want to use the direct path to the binaries, instead of a combination of ``--sandbox-binary`` and the version name.
318
+
319
+
For example, let's assume your binaries are organized as follows:
320
+
321
+
$HOME/opt/
322
+
/percona/
323
+
/5.7.21
324
+
/5.7.22
325
+
/8.0.11
326
+
/mysql/
327
+
/5.7.21
328
+
/5.7.22
329
+
/8.0.11
330
+
331
+
You can deploy a single sandbox for a Percona server version 5.7.22 using any of the following approaches:
332
+
333
+
#1
334
+
dbdeployer deploy single --sandbox-binary=$HOME/opt/percona 5.7.22
Methods #1 and #2 are equivalent. They set the sandbox binary directory temporarily to a new one, and use it for the current deployement
348
+
349
+
Methods #3 and #4 will set the sandbox binary directory permanently, with the difference that #3 is set for any invocation of dbdeployer system-wide (in a different terminal window, it will use the new value,) while #4 is set only for the current session (in a different terminal window, it will still use the default.)
350
+
351
+
Be aware that, using this kind of organization may see conflicts during deployment. For example, after installing Percona Server 5.7.22, if you want to install MySQL 5.7.22 you will need to specify a ``--sandbox-directory`` explicitly.
352
+
Instead, if you use the prefix approach defined in the "standard and non-standard basedir names," conflicts should be avoided.
353
+
307
354
## Ports management
308
355
309
356
dbdeployer will try using the default port for each sandbox whenever possible. For single sandboxes, the port will be the version number without dots: 5.7.22 will deploy on port 5722. For multiple sandboxes, the port number is defined by using a prefix number (visible in the defaults: ``dbdeployer defaults list``) + the port number + the revision number (for some topologies multiplied by 100.)
@@ -755,18 +802,18 @@ Should you need to compile your own binaries for dbdeployer, follow these steps:
755
802
2. Run ``go get github.com/datacharmer/dbdeployer``. This will import all the code that is needed to build dbdeployer.
756
803
3. Change directory to ``$GOPATH/src/github.com/datacharmer/dbdeployer``.
757
804
4. From the folder ``./pflag``, copy the file ``string_slice.go`` to ``$GOPATH/src/github.com/spf13/pflag``.
758
-
5. Run ``./build.sh {linux|OSX} 1.7.0``
759
-
6. If you need the docs enabled binaries (see the section "Generating additional documentation") run ``MKDOCS=1 ./build.sh {linux|OSX} 1.7.0``
805
+
5. Run ``./build.sh {linux|OSX} 1.8.0``
806
+
6. If you need the docs enabled binaries (see the section "Generating additional documentation") run ``MKDOCS=1 ./build.sh {linux|OSX} 1.8.0``
760
807
761
808
## Generating additional documentation
762
809
763
810
Between this file and [the API API list](https://github.com/datacharmer/dbdeployer/blob/master/docs/API/API-1.1.md), you have all the existing documentation for dbdeployer.
764
811
Should you need additional formats, though, dbdeployer is able to generate them on-the-fly. Tou will need the docs-enabled binaries: in the distribution list, you will find:
765
812
766
-
* dbdeployer-1.7.0-docs.linux.tar.gz
767
-
* dbdeployer-1.7.0-docs.osx.tar.gz
768
-
* dbdeployer-1.7.0.linux.tar.gz
769
-
* dbdeployer-1.7.0.osx.tar.gz
813
+
* dbdeployer-1.8.0-docs.linux.tar.gz
814
+
* dbdeployer-1.8.0-docs.osx.tar.gz
815
+
* dbdeployer-1.8.0.linux.tar.gz
816
+
* dbdeployer-1.8.0.osx.tar.gz
770
817
771
818
The executables containing ``-docs`` in their name have the same capabilities of the regular ones, but in addition they can run the *hidden* command ``tree``, with alias ``docs``.
0 commit comments