| Server IP : 3.147.158.171 / Your IP : 216.73.216.216 Web Server : Apache/2.4.67 (Amazon Linux) OpenSSL/3.5.5 System : Linux ip-172-31-2-178.us-east-2.compute.internal 6.1.172-216.329.amzn2023.x86_64 #1 SMP PREEMPT_DYNAMIC Wed May 20 06:31:34 UTC 2026 x86_64 User : ec2-user ( 1000) PHP Version : 8.4.21 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /tsai/repo/builder/backend/configs/ |
Upload File : |
{
"name": "Local DBs from Production",
"description": "Sync production databases, backup local databases, then restore from production backups",
"steps": [
{
"name": "Backup local databases",
"step_type": "shell",
"command": "python db_back.py --backup-dir ${BASE_DIR}bak/db-local wp_jpt drupal scike wp_demo_tsai wp_tsai2 wp_sandbox wp_autosave wp_dev wp_news",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 600
},
{
"name": "Restore drupal from production",
"step_type": "shell",
"command": "python db_restore.py drupal --backup-dir ${BASE_DIR}bak/db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Localize Drupal site_config hosts",
"step_type": "shell",
"command": "python localize_site_configs.py",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 120
},
{
"name": "Clear drupal cache",
"step_type": "shell",
"command": "./vendor/bin/drush cr",
"working_dir": "${BASE_DIR}drupal",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Restore scike (store) from production",
"step_type": "shell",
"command": "python db_restore.py scike --backup-dir ${BASE_DIR}bak/scike-db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Clear store cache",
"step_type": "shell",
"command": "./vendor/bin/drush cr",
"working_dir": "${BASE_DIR}store",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Restore wp_jpt from production",
"step_type": "shell",
"command": "python db_restore.py wp_jpt --backup-dir ${BASE_DIR}bak/db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Search-replace wp_jpt URLs",
"step_type": "shell",
"command": "wp search-replace 'https://johnturman.net' 'http://johnturman.test' && wp option update tsai_api_url 'http://127.0.0.1:8000/api/v1'",
"working_dir": "${BASE_DIR}sites/johnturman.net",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Restore wp_demo_tsai from production",
"step_type": "shell",
"command": "python db_restore.py wp_demo_tsai --backup-dir ${BASE_DIR}bak/db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Search-replace wp_demo_tsai URLs",
"step_type": "shell",
"command": "wp search-replace 'https://demo.turmansolutions.ai' 'http://demo.turmansolutions.test' && wp option update tsai_api_url 'http://127.0.0.1:8000/api/v1'",
"working_dir": "${BASE_DIR}sites/demo.tsai.ai",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Restore wp_tsai2 from production",
"step_type": "shell",
"command": "python db_restore.py wp_tsai2 --backup-dir ${BASE_DIR}bak/db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Search-replace wp_tsai2 URLs",
"step_type": "shell",
"command": "wp search-replace 'https://turmansolutions.ai' 'http://turmansolutions.test' && wp option update tsai_api_url 'http://127.0.0.1:8000/api/v1'",
"working_dir": "${BASE_DIR}sites/tsai2",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Restore wp_sandbox from production",
"step_type": "shell",
"command": "python db_restore.py wp_sandbox --backup-dir ${BASE_DIR}bak/db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Search-replace wp_sandbox URLs",
"step_type": "shell",
"command": "wp search-replace 'https://sandbox.turmansolutions.ai' 'http://sandbox.turmansolutions.test' && wp option update tsai_api_url 'http://127.0.0.1:8000/api/v1'",
"working_dir": "${BASE_DIR}sites/sandbox",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Restore wp_autosave from production",
"step_type": "shell",
"command": "python db_restore.py wp_autosave --backup-dir ${BASE_DIR}bak/db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Search-replace wp_autosave URLs",
"step_type": "shell",
"command": "wp search-replace 'https://autosave.turmansolutions.ai' 'http://autosave.turmansolutions.test' && wp option update tsai_api_url 'http://127.0.0.1:8000/api/v1'",
"working_dir": "${BASE_DIR}sites/autosave",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Restore wp_dev from production",
"step_type": "shell",
"command": "python db_restore.py wp_dev --backup-dir ${BASE_DIR}bak/db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Search-replace wp_dev URLs",
"step_type": "shell",
"command": "wp search-replace 'https://dev.turmansolutions.ai' 'http://dev.turmansolutions.test' && wp option update tsai_api_url 'http://127.0.0.1:8000/api/v1'",
"working_dir": "${BASE_DIR}sites/dev",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Restore wp_news from production",
"step_type": "shell",
"command": "python db_restore.py wp_news --backup-dir ${BASE_DIR}bak/db --yes",
"working_dir": "${BASE_DIR}builder/backend/scripts",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
},
{
"name": "Search-replace wp_news URLs",
"step_type": "shell",
"command": "wp search-replace 'https://news.turmansolutions.ai' 'http://news.turmansolutions.test' && wp option update tsai_api_url 'http://127.0.0.1:8000/api/v1'",
"working_dir": "${BASE_DIR}sites/news",
"environment": {
"PATH": "${MAMP_MYSQL_BIN}:${MAMP_PHP_BIN}:${PATH}"
},
"timeout": 300
}
],
"stop_on_failure": true
}