CARVIEW |
Select Language
HTTP/2 200
date: Wed, 23 Jul 2025 17:36:46 GMT
content-type: text/html; charset=utf-8
vary: X-PJAX, X-PJAX-Container, Turbo-Visit, Turbo-Frame, X-Requested-With,Accept-Encoding, Accept, X-Requested-With
x-robots-tag: none
etag: W/"681f1c9f18c2cf2095effb0c6e3d38f2"
cache-control: max-age=0, private, must-revalidate
strict-transport-security: max-age=31536000; includeSubdomains; preload
x-frame-options: deny
x-content-type-options: nosniff
x-xss-protection: 0
referrer-policy: no-referrer-when-downgrade
content-security-policy: default-src 'none'; base-uri 'self'; child-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/; connect-src 'self' uploads.github.com www.githubstatus.com collector.github.com raw.githubusercontent.com api.github.com github-cloud.s3.amazonaws.com github-production-repository-file-5c1aeb.s3.amazonaws.com github-production-upload-manifest-file-7fdce7.s3.amazonaws.com github-production-user-asset-6210df.s3.amazonaws.com *.rel.tunnels.api.visualstudio.com wss://*.rel.tunnels.api.visualstudio.com objects-origin.githubusercontent.com copilot-proxy.githubusercontent.com proxy.individual.githubcopilot.com proxy.business.githubcopilot.com proxy.enterprise.githubcopilot.com *.actions.githubusercontent.com wss://*.actions.githubusercontent.com productionresultssa0.blob.core.windows.net/ productionresultssa1.blob.core.windows.net/ productionresultssa2.blob.core.windows.net/ productionresultssa3.blob.core.windows.net/ productionresultssa4.blob.core.windows.net/ productionresultssa5.blob.core.windows.net/ productionresultssa6.blob.core.windows.net/ productionresultssa7.blob.core.windows.net/ productionresultssa8.blob.core.windows.net/ productionresultssa9.blob.core.windows.net/ productionresultssa10.blob.core.windows.net/ productionresultssa11.blob.core.windows.net/ productionresultssa12.blob.core.windows.net/ productionresultssa13.blob.core.windows.net/ productionresultssa14.blob.core.windows.net/ productionresultssa15.blob.core.windows.net/ productionresultssa16.blob.core.windows.net/ productionresultssa17.blob.core.windows.net/ productionresultssa18.blob.core.windows.net/ productionresultssa19.blob.core.windows.net/ github-production-repository-image-32fea6.s3.amazonaws.com github-production-release-asset-2e65be.s3.amazonaws.com insights.github.com wss://alive.github.com api.githubcopilot.com api.individual.githubcopilot.com api.business.githubcopilot.com api.enterprise.githubcopilot.com; font-src github.githubassets.com; form-action 'self' github.com gist.github.com copilot-workspace.githubnext.com objects-origin.githubusercontent.com; frame-ancestors 'none'; frame-src viewscreen.githubusercontent.com notebooks.githubusercontent.com; img-src 'self' data: blob: github.githubassets.com media.githubusercontent.com camo.githubusercontent.com identicons.github.com avatars.githubusercontent.com private-avatars.githubusercontent.com github-cloud.s3.amazonaws.com objects.githubusercontent.com release-assets.githubusercontent.com secured-user-images.githubusercontent.com/ user-images.githubusercontent.com/ private-user-images.githubusercontent.com opengraph.githubassets.com copilotprodattachments.blob.core.windows.net/github-production-copilot-attachments/ github-production-user-asset-6210df.s3.amazonaws.com customer-stories-feed.github.com spotlights-feed.github.com objects-origin.githubusercontent.com *.githubusercontent.com; manifest-src 'self'; media-src github.com user-images.githubusercontent.com/ secured-user-images.githubusercontent.com/ private-user-images.githubusercontent.com github-production-user-asset-6210df.s3.amazonaws.com gist.github.com; script-src github.githubassets.com; style-src 'unsafe-inline' github.githubassets.com; upgrade-insecure-requests; worker-src github.githubassets.com github.com/assets-cdn/worker/ github.com/assets/ gist.github.com/assets-cdn/worker/
server: github.com
content-encoding: gzip
accept-ranges: bytes
set-cookie: _gh_sess=vdRwzkLmDS1P0HzGu2gnPRGRaJAEqD364KhYulKDylyUXvw1eCa%2Fx4ekGEiYlbhsvFKPBNZzlQwxp4XurOOHJyhwqOkbvb%2Fjp0zHRLmqeiv4BrqRj5HYOf3LrmMAOxHUQWZVFiWOSN4DkNVwy3WAv9NC2r53xcqPKRscmIcYgPZQBMYzPIwxUrijaFrVzH03gsHG%2FFBErD6oSxrDiQ8CN4DIXi6QumY06iSQeZ3c2V7HS15JZgbnbM74aIyaoWpcerrr3xDxLT5JelQEZXkGbA%3D%3D--XTT0RiZ5lpGBVbzI--N%2BDp4aVwe9P%2FzBJAl5nVxA%3D%3D; Path=/; HttpOnly; Secure; SameSite=Lax
set-cookie: _octo=GH1.1.380266664.1753292206; Path=/; Domain=github.com; Expires=Thu, 23 Jul 2026 17:36:46 GMT; Secure; SameSite=Lax
set-cookie: logged_in=no; Path=/; Domain=github.com; Expires=Thu, 23 Jul 2026 17:36:46 GMT; HttpOnly; Secure; SameSite=Lax
x-github-request-id: A336:20AC8F:F4A64C:12151EC:68811DAE
sandbox customization · datacharmer/dbdeployer Wiki · GitHub
Skip to content
Navigation Menu
{{ message }}
This repository was archived by the owner on Oct 29, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 153
sandbox customization
Giuseppe Maxia edited this page Mar 17, 2021
·
3 revisions
[HOME]
There are several ways of changing the default behavior of a sandbox.
- You can add options to the sandbox being deployed using
--my-cnf-options="some mysqld directive"
. This option can be used many times. The supplied options are added to my.sandbox.cnf - You can specify a my.cnf template (
--my-cnf-file=filename
) instead of defining options line by line. dbdeployer will skip all the options that are needed for the sandbox functioning. - You can run SQL statements or SQL files before or after the grants were loaded (
--pre-grants-sql
,--pre-grants-sql-file
, etc). You can also use these options to peek into the state of the sandbox and see what is happening at every stage. - For more advanced needs, you can look at the templates being used for the deployment, and load your own instead of the original s(
--use-template=TemplateName:FileName
.)
For example:
$ dbdeployer deploy single 5.6.33 --my-cnf-options="general_log=1" \
--pre-grants-sql="select host, user, password from mysql.user" \
--post-grants-sql="select @@general_log"
$ dbdeployer defaults templates list
$ dbdeployer defaults templates show templateName > mytemplate.txt
# edit the template
$ dbdeployer deploy single --use-template=templateName:mytemplate.txt 5.7.21
dbdeployer will use your template instead of the original.
- You can also export the templates, edit them, and ask dbdeployer to edit your changes.
Example:
$ dbdeployer defaults templates export single my_templates
# Will export all the templates for the "single" group to the directory my_templates/single
$ dbdeployer defaults templates export ALL my_templates
# exports all templates into my_templates, one directory for each group
# Edit the templates that you want to change. You can also remove the ones that you want to leave untouched.
$ dbdeployer defaults templates import single my_templates
# Will import all templates from my_templates/single
Warning: modifying templates may block the regular work of the sandboxes. Use this feature with caution!
- Finally, you can modify the defaults for the application, using the "defaults" command. You can export the defaults, import them from a modified JSON file, or update a single one on-the-fly.
Here's how:
$ dbdeployer defaults show
# Internal values:
{
"version": "1.5.0",
"sandbox-home": "$HOME/sandboxes",
"sandbox-binary": "$HOME/opt/mysql",
"use-sandbox-catalog": true,
"master-slave-base-port": 11000,
"group-replication-base-port": 12000,
"group-replication-sp-base-port": 13000,
"fan-in-replication-base-port": 14000,
"all-masters-replication-base-port": 15000,
"multiple-base-port": 16000,
"group-port-delta": 125,
"mysqlx-port-delta": 10000,
"master-name": "master",
"master-abbr": "m",
"node-prefix": "node",
"slave-prefix": "slave",
"slave-abbr": "s",
"sandbox-prefix": "msb_",
"master-slave-prefix": "rsandbox_",
"group-prefix": "group_msb_",
"group-sp-prefix": "group_sp_msb_",
"multiple-prefix": "multi_msb_",
"fan-in-prefix": "fan_in_msb_",
"all-masters-prefix": "all_masters_msb_",
"reserved-ports": [
1186,
3306,
33060
],
"timestamp": "Sat May 12 14:37:53 CEST 2018"
}
$ dbdeployer defaults update master-slave-base-port 15000
# Updated master-slave-base-port -> "15000"
# Configuration file: $HOME/.dbdeployer/config.json
{
"version": "1.5.0",
"sandbox-home": "$HOME/sandboxes",
"sandbox-binary": "$HOME/opt/mysql",
"use-sandbox-catalog": true,
"master-slave-base-port": 15000,
"group-replication-base-port": 12000,
"group-replication-sp-base-port": 13000,
"fan-in-replication-base-port": 14000,
"all-masters-replication-base-port": 15000,
"multiple-base-port": 16000,
"group-port-delta": 125,
"mysqlx-port-delta": 10000,
"master-name": "master",
"master-abbr": "m",
"node-prefix": "node",
"slave-prefix": "slave",
"slave-abbr": "s",
"sandbox-prefix": "msb_",
"master-slave-prefix": "rsandbox_",
"group-prefix": "group_msb_",
"group-sp-prefix": "group_sp_msb_",
"multiple-prefix": "multi_msb_",
"fan-in-prefix": "fan_in_msb_",
"all-masters-prefix": "all_masters_msb_",
"reserved-ports": [
1186,
3306,
33060
],
"timestamp": "Sat May 12 14:37:53 CEST 2018"
}
Another way of modifying the defaults, which does not store the new values in dbdeployer's configuration file, is through the --defaults
flag. The above change could be done like this:
$ dbdeployer --defaults=master-slave-base-port:15000 \
deploy replication 5.7.21
The difference is that using dbdeployer defaults update
the value is changed permanently for the next commands, or until you run a dbdeployer defaults reset
. Using the --defaults
flag, instead, will modify the defaults only for the active command.
Clone this wiki locally
You can’t perform that action at this time.