LogoLogo
Deploy NowCommunity Careers
  • Introduction to StackAI
  • Litepaper
  • FAQs
    • Introductory FAQs
    • Technical FAQs
    • Project/App FAQ
    • Financial FAQs
  • Tokens
    • Add $STACK to MetaMask
    • Buy $STACK Tokens
  • App Deployment on StackOS
    • Custom App Deployment
    • AppStore App Deployment
    • Deploy a Containerized Application on StackOS
  • Basic Operations
    • Create WebTTY
    • WebTTY, Logs, Shell Access
    • Practice - Persistent Data, Alternate User
    • Reset StackOS Account
    • Map a container port
    • Custom DNS
    • Custom SSL
    • Account Funding - General
    • Pod Launch - General
  • Preparing Custom Images
    • Docker Hub Intro
    • GitHub, DockerHub and StackOS Integration
  • App Store Notes
    • Redis on StackOS
    • Memcached on StackOS
    • Presearch on StackOS
    • Wordpress on StackOS
    • Jenkins on StackOS
    • WebDAV on StackOS
  • Useful Apps
    • phpMyAdmin (Mysql Web Admin)
  • Wordpress Operations
    • Launching a Wordpress app on StackOS
    • WordPress Migration
    • Account Funding - Wordpress
    • Upload limit increase
    • SSL Mixed Content Resolution
    • Wordpress Domain Change
  • Other Applications
    • Python Applications
    • RSK
  • 0xMarket
    • Viewing your NodeNFT
    • Listing your NodeNFT
    • Buying a NodeNFT
Powered by GitBook
On this page
  • Method 1:
  • Method 2:
  1. Wordpress Operations

Wordpress Domain Change

PreviousSSL Mixed Content ResolutionNextPython Applications

Last updated 3 years ago

WordPress reacts interestingly to domain changes and will try to "help you" by sending you to the previous official domain (even if you no longer want to use it).

There are different ways to handle this, some more involved than others.

The combination of settings, themes, plugins, content and customizations will determine the best method. It is not possible to recommend in advance.Note: Migrating from your to test.stackos.io, then from to are two domain name migrations.

Method 1:

Allocate a second set of servers and use migration tool to smooth out any domain changes in the database, plugins, and themes

Example: Migrate from to

This is a reasonable strategy if you already are familiar with migrations and want to do it again

For example, if you already migrated from ->

And now you simply want to do it again from -> real.domain.com

If both and the new are both on StackOS, be sure to have enough resources to run both sets of pods at the same time.

For guidance, check this link:

Then search for: "Trying to migrate an existing test/production site?"

Method 2:

Try to see if a domain name change only will be sufficient (may require additional database edits after)

Try to see if overriding the domain in the config is enough to stop the wordpress redirect. This will depend on all your plugsins/themes/database data cooperating which varies case by case.

To be clear, this is not a StackOS issue. You would encounter this issue if you were switching domains on a traditional server.

webtty and exec a shell into your wordpress pod

Then set the following overrides in wp-config.php by doing the following: You will need to install an editor

apt update

apt install -y nano vim

Use the editor you know (nano if you don't know)

nano wp-config.php

Search for this line:

/* Add any custom values between this line and the "stop editing" line. */

// Define wp home and site url

define('WP_HOME','https://MYDOMAIN.COM');

define('WP_SITEURL','https://MYDOMAIN.COM');

Save your edits (Control+X in nano). Test your site again.

If some things work and other things don't, then you'll need to either consider

  • Method 1 - Migration as above

  • Checking each plugin/theme/content piece to determine which item is "stuck/hardcoded" for the previous domain

original.domain.com
test.stackos.io
real.stackos.io
test.domain.com
real.domain.com
real.domain.com
test.domain.com
test.domain.com
test.domain.com
real.domain.com
StackOS Wordpress Migration Guidance
Create WebTTY
WebTTY, Logs, Shell Access