I'm asked to write documentation explaining how to set up a website to run exactly as the live environment does right now.

The website is dependent on WPML, certain categories and menu's being created and certain pages to exist on specific templates.

What would be the correct way to deliver some sort of installation script so that a clean WP install would be set up as needed without having someone go through every step manually like "Setup WPML with these languages" "Set these text-domains to language x" "Create these categories" etc.

On Laravel applications we run migration scripts that seed the database with all prerequired info, but for WP I have no idea how to start.

  • 1
    Why "set up" a clean install instead of copying the live environment and only changing paths? – kero Jun 29 at 11:48
  • Because due to company policies the IT party responsible for deployment is not allowed to import/export data. Don't get me started it's ridiculous. They want a complete written documentation with every single step to get the website where it was when we deployed it because we're not allowed access to the environment. So I figure i'd write them some scripts or whatever but I have no idea how to with WP – Jeffrey von Grumbkow Jun 29 at 12:51

I've had great luck with scripting WP-CLI to install, setup and configure WordPress development, staging, and production sites.

With it, you can automate nearly the entire process including the installation of specific plugins, the creation of menus, categories, and just about any WordPress configuration item.

Obviously, this approach would require shell access and the installation of WP-CLI.

  • I wasn't aware WP-CLI could do more than installing WP and plugins! I'll see if I can write a script that does the initial setup :) – Jeffrey von Grumbkow Jun 30 at 21:46

Your Answer

 
discard

By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.

Not the answer you're looking for? Browse other questions tagged or ask your own question.