Skip to content
Run Shifter WordPress Image Localy.
Branch: master
Clone or download
Latest commit 6afd5cf Sep 13, 2018
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
.circleci
.gitignore write README Jan 4, 2018
LICENSE
README.md Update README.md Sep 13, 2018
docker-compose.yml add comment Feb 14, 2018
docker-compose_linux.yml add docker-compose_linux.yml Jan 24, 2018
package.json added package.json for testing Feb 7, 2018

README.md

Shifter - Local

CircleCI

shifter_local

Docker image for testing WordPress themes and plugins while migrating to Shifter. This image is also available on Dockerhub.

Requirements

  • docker
  • docker-compose

Getting Started

git clone https://github.com/getshifter/shifter-local.git
cd shifter-local
docker-compose up -d

Visit https://127.0.0.1:8443 in your browser.

Use Ctl + C in your terminal window to stop running containers.

Linux

Considering file permissions, we recommend using volumes on Linux.

docker-compose -f docker-compose.yml -f docker-compose_linux.yml up

Updating Docker Image

docker-compose pull

Storage

  • MacOS
    • ./volume/app: wordpress/wp-content files
    • ./volume/db: mysql databases
  • Linux (detect path using docker volume inspect)
    • /var/lib/docker/volumes/shifterlocal_app/_data: wordpress/wp-content files
    • /var/lib/docker/volumes/shifterlocal_db/_data: mysql databases

All data will be persisted in these directories, even if the Docker containers are stopped.

To start over with the installation, simply delete ./volume/ of docker volume rm.

Debugging

Some plugins and themes may conflict with Shifter. Conflicts usually cause the Generator to hang or fail. Here are a few tips.

Check for a valid JSON format

Your site should return a list of valid URLs in JSON format for Shifter to crawl for generating.

Add ?url=0 to the websites URL to test.

https://127.0.0.1:8443?urls=0

Check for list of all target pages

If the number of pages to be generated is more than 100, you can check the target by 100 pages by increasing the number of the urls parameter. (e.g. urls=1, urls=2)

Pages that do not appear in this list are not subject to generate.

Common problems and solutions when there are no pages in the list are as follows.

  • pagination issues. (Work in progress)

Displaying PHP Errors

While running your site on Shifters production environment PHP warning are suppressed. These warning if any are visible while running Shifter-Local for debugging your theme.

Considerations

  • Depending on your local environment mail functions may send from this container. Example: Under Outbound Port 25 Blocking

Disclaimer

This Docker image is similar to the one used by Shifter, but does not guarantee complete compatibility.

You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.