Open Trellis databases in Sequel Pro with a single command
Built with ♥ by Typist Tech
Vagrant Trellis Sequel is an open source project and completely free to use.
However, the amount of effort needed to maintain and develop new features is not sustainable without proper financial backing. If you have the capability, please consider donating using the links below:
$ vagrant trellis-sequel open --help
Usage: vagrant trellis-sequel open [options] [vm-id]
--site [site] Site whose database going to be opened.
--vault-password-file [VAULT_PASSWORD_FILE]
Vault password file.
--vault-pass [VAULT_PASS] Vault password.
-h, --help Print this help
$ vagrant trellis-sequel open
This works for most of the cases:
vault.yml
is unencryptedvault.yml
is encrypted and.vault_pass
contains the vault password- running from within the Trellis directory
- open the first found database
$ vagrant trellis-sequel open --site example.com
Use the --site
option to specify which site's database to open. By default, the first site's database will be opened.
Note: This is the site key of vault_wordpress_sites
in vault.yml
, usually ends with .com
.
$ vagrant trellis-sequel open --vault-password-file .my_vault_password_file
$ vagrant trellis-sequel open --vault-password-file /my/top/secret.txt
Use the --vault-password-file
option to specify path to the vault password file, either relative path from Trellis root or absolute path.
Default value is .vault_pass
if vault.yml
is encrypted.
$ vagrant trellis-sequel open --vault-pass my-top-secret
Use the --vault-pass
option to provide vault password if you encrypted vault.yml
but don't have a vault password file.
Typist Tech is ready to build your next awesome WordPress site. Hire us!
$ vagrant plugin install vagrant-trellis-sequel
That means you passed wrong --site
or vault.yml
is malformed.
# group_vars/development/vault.yml
vault_wordpress_sites:
example.com:
admin_password: admin
env:
db_password: bye
www.typist.tech:
admin_password: admin
env:
db_password: hello
For the above vault.yml
, these 3 commands are valid:
$ vagrant trellis-sequel open # Open one of the DB, most likely the first one
$ vagrant trellis-sequel open --site example.com
$ vagrant trellis-sequel open --site www.typist.tech
That means vault password is incorrect.
This part is stolen from from Sequel Pro for Chassis.
If you get a connection error, the first thing to attempt to debug is to check the details that Sequel Pro gives you (under the Show Details button).
If you get this error on macOS Sierra, it's possible that you have too many SSH keys loaded into your ssh-agent
. If you're using multiple boxes with this setup in your SSH config (AddKeysToAgent yes
), each new box you add will be added to your agent. With too many of these, SSH will hit the authentication retries limit before getting to the correct key.
The simple solution is to add this to your ~/.ssh/config
file:
# Disable checks on Vagrant machines
Host 127.0.0.1
# Skip adding to agent
AddKeysToAgent no
# Only use key specified on CLI
IdentitiesOnly yes
# Skip known hosts
UserKnownHostsFile /dev/null
StrictHostKeyChecking no
This disables using system-level keys (both from the agent, and your regular SSH keys), and disables host checks (which are not necessary for localhost). This does not affect vagrant ssh
, which already uses these options.
If you want to open non-vagrant databases, i.e: production or staging databases on remote sevrers, use $ trellis db open
instead.
Make sure your hosts file (/etc/hosts
) contains all the domains you're self-signing.
Usually it can be rectified by $ vagrant reload --provision
or $ vagrant hostmanager
.
Ask on Root Discourse if the problem persists.
- Articles on Typist Tech's blog
- Tang Rufus' WordPress plugins on wp.org
- More projects on Typist Tech's GitHub profile
- Stay tuned on Typist Tech's newsletter
- Follow Tang Rufus' Twitter account
- Hire Tang Rufus to build your next awesome site
Thanks! Glad you like it. It's important to let me knows somebody is using this project. Please consider:
- tweet something good with mentioning @TangRufus
- ★ star the Github repo
- 👀 watch the Github repo
- write tutorials and blog posts
- hire Typist Tech
Please provide feedback! We want to make this project as useful as possible. Please submit an issue and point out what you do and don't like, or fork the project and send pull requests. No issue is too small.
If you discover a security vulnerability within this project, please email us at [email protected]. All security vulnerabilities will be promptly addressed.
Vagrant Trellis Sequel is a Typist Tech project and maintained by Tang Rufus, freelance developer for hire.
Inspired from Sequel Pro for Chassis.
Special thanks to the Roots team whose Trellis make this project possible.
Full list of contributors can be found here.
Vagrant Trellis Sequel is released under the MIT License.