# Remote MySQL

**URL:** https://discourse.roots.io/t/remote-mysql/4395
**Category:** trellis
**Created:** 2015-08-04T02:50:49Z
**Posts:** 5

## Post 1 by @brandon — 2015-08-04T02:50:49Z

After I finally got `AWS` up and running, I have another question.

I’ve manually set my endpoint under `db_host: database.us-east-1.rds.amazonaws.com`

The instructions for a normal `wp-config.php` install makes sense, un, pw, and host, and off we go. However, with `trellis` it’s a bit confusing.

Would you mind helping a bIt?

---

## Post 2 by @kalenjohnson — 2015-08-04T03:07:28Z

Sorry, I don’t folllow the question. You are asking how to connect to your MySQL datbase remotely? Are you talking about from the Bedrock installation, or from an app like Sequel Pro?

---

## Post 3 by @brandon — 2015-08-04T03:36:07Z

I’m talking using `RDS` instead of using `mysql` directly on the app server.

---

## Post 4 by @austin — 2015-08-04T03:41:27Z

Check the trellis readme at the bottom

env - environment variables

And it’s nested variables

wp\_home - WP\_HOME constant (required)  
wp\_siteurl - WP\_SITEURL constant (required)  
wp\_env - environment (required, matches group name: development, staging, production)  
db\_name - database name (required)  
db\_user - database username (required)  
db\_password - database password (required)  
db\_host - database hostname (default: localhost)  
domain\_current\_site (required if multisite.enabled is true)

---

## Post 5 by @swalkinshaw — 2015-08-04T03:56:21Z

You need to set your `DB_HOST`, `DB_USERNAME`, and `DB_PASSWORD` as usual of course to match your RDS credentials.

Also set `db_create` to `false`. The main difference with a remote db is you need to make sure the database is already create outside of Trellis.

Note that some changes are coming to this workflow. See [https://github.com/roots/trellis/pull/239](https://github.com/roots/trellis/pull/239)
