littlebizzy / slickstack

Lightning-fast WordPress on Nginx
https://slickstack.io
GNU General Public License v3.0
643 stars 113 forks source link

Want to use remote database but SS overwrites my wp-config edits? #95

Closed ogcreid closed 3 years ago

ogcreid commented 3 years ago

A consultant set up a Worldpress instance on AWS lightsail for me.

I wane to move the database to an RDS database (where I have managed to set up a copy of the Wordpress db))

There is warning in the WP config file saying Slickstack will overwrite any edits, and that is indeed what happens

So how do I get WP to point to external db now?

corzel commented 3 years ago
  1. You must set your ss-config file with the info of your external database (DB_NAME, DB_USER, DB_PASSWORD, etc.) DB_HOST="IP of your AWS lightsail instance".
  2. Run ss-update.

I use SS with an external db without a problem.

jessuppi commented 3 years ago

Hello @ogcreid yes what @corzel said is correct, be sure to update ss-config options first before anything, and then you can reinstall WordPress config using ss install wp config command.

The relevant options to change would be:

DB_NAME="@DB_NAME"
DB_USER="@DB_USER"
DB_PASSWORD="@DB_PASSWORD_USER"
DB_PASSWORD_ROOT="@DB_PASSWORD_ROOT"
DB_HOST="@DB_HOST"
DB_PREFIX="@DB_PREFIX"
DB_CHARSET="utf8mb4"
DB_COLLATE=""

Ref: https://github.com/littlebizzy/slickstack/blob/master/bash/ss-config-sample.txt