瀏覽代碼

Update siteurl and home in the database

Girish Ramakrishnan 7 年之前
父節點
當前提交
b75e00a93c
共有 1 個文件被更改,包括 6 次插入0 次删除
  1. 6 0
      start.sh

+ 6 - 0
start.sh

@@ -94,6 +94,12 @@ else
     echo "Plugins already unpacked from previous run" # restarts
 fi
 
+echo "Updating domain related settings"
+# Note that wp-config already sets WP_HOME and WP_SITEURL and the values in db below are ignored
+# This is only done for keeping the db dumps more useful
+$WP option update siteurl "${APP_ORIGIN}"
+$WP option update home "${APP_ORIGIN}"
+
 # configure WP mail smtp plugin (smtp_user, smtp_pass can be set when supported)
 echo "Configuring smtp mail"
 $WP option update mailer smtp