Skip to content

JGodin-C2C/jahia2wp

 
 

Repository files navigation

jahia2wp
jahia2wp

Control your migration from Jahia to WordPress

Changelog RDT Travis Codecov License


Install and Usage

Head to the documentation for next practical steps

Roadmap and Overview

30/11/2017, Naked WordPress : Went Live ✈️

We spent 6 sprints to focus on automation and maintenance, with the objective of driving all the creation process from one shared spreadsheet (aka configuration source).

  1. 🎈 installing a functional WordPress to any given URL

    1. Create a file named generate.yaml containing the following:
      langs: en
      unit_name: si-dev
      unit_id: 13028
1. Type the following commands:
    $ export PLUGINS_CONFIG_BASE_PATH=/srv/$WP_ENV/jahia2wp/data/plugins
    $ python jahia2wp.py generate $WP_ENV http://localhost --extra-config=generate.yaml --admin-password=admin
    $ wp --path=/srv/$WP_ENV/localhost/htdocs option update plugin:epfl_tequila:has_dual_auth 1
    $ python jahia2wp.py generate $WP_ENV http://localhost/test2 --extra-config=generate.yaml --admin-password=admin
    $ wp --path=/srv/$WP_ENV/localhost/htdocs/test2 option update plugin:epfl_tequila:has_dual_auth 1
    ...

    $ python jahia2wp.py check $WP_ENV http://localhost
    WordPress site valid and accessible at http://localhost

    $ python jahia2wp.py admins $WP_ENV http://localhost
    admin:admin@example.com <administrator>
    user123456:user@epfl.ch <administrator>

💡 In lieu of the --admin-password flag, one can gain access through PHPMyAdmin 💡 If you want to start over with a clean slate (e.g. after an error):

    $ rm -rf /srv/$WP_ENV/localhost/htdocs/
  1. 🎉 add, list plugins

     $ python jahia2wp.py extract-plugin-config $WP_ENV http://localhost output_file
     ...
    
     $ python jahia2wp.py list-plugins $WP_ENV http://localhost
     Plugin list for site 'localhost':
     - mainwp-child
       - action   : install
       - activated: True
       - src      : web
     - tequila
       - action   : install
       - activated: True
     ...
    
     $ python jahia2wp.py list-plugins $WP_ENV http://localhost --config --plugin=tequila      - tequila
     - action     : install
       - activated: True
       - src      : /srv/ebreton/jahia2wp/data/plugins/generic/tequila/v1/tequila.zip
     - tables
       + term_relationships
       + termmeta
       + terms
       + options
       + term_taxonomy
       + postmeta
    
  2. 🚧 maintaining the website and the plugins

     $ python jahia2wp.py version $WP_ENV http://localhost
     4.8
    
     $ python jahia2wp.py clean $WP_ENV http://localhost
     ...
    
     $ python jahia2wp.py backup $WP_ENV http://localhost
     ...
    
  3. 🍾 applying those them functionalities to every row of our configuration source

     $ python jahia2wp.py generate-many path/to/source.csv
     ...
    
     $ python jahia2wp.py backup-many path/to/source.csv
     ...
    
     $ python jahia2wp.py inventory $WP_ENV /srv/your-env/localhost
     INFO - your-env - inventory - Building inventory...
     path;valid;url;version;db_name;db_user;admins
     ...
    

Migration

  1. 💝 Export the content of a Jahia website as a zipped package

     $ python jahia2wp.py download dcsl --username=foo
     Jahia password for user 'foo':
     ...
    
  2. ⛺ Parse zipped package (XML and files) as python objects

  3. ⛺ Import parsed pages into WordPress (raw content)

  4. ⛺ Support translation, hierarchy, menu, sidebar

  5. Import static Jahia boxes into WordPress (shortcodes)

  6. Import web-services powered Jahia boxes into WordPress (people, faq, actu, memento, infoscience, and so on ...)

Help

Calling jahia2wp.py with -h will give you details on available options

$ python jahia2wp.py -h
...

Changelog

All notable changes to this project are documented in CHANGELOG.md.

Contribution

Check out CONTRIBUTING.md for more details

As well as our CODE_OF_CONDUCT.md, where we pledge to making participation in our project and our community a harassment-free experience for everyone

Contributor list

Big up to all the following people, without whom this project will not be


Manu B.


Manu J.


Greg


Lulu


Laurent


Luc



Dominique


Nicolas


William


CampToCamp



About

Migrate your site from Jahia to WordPress

Resources

License

Code of conduct

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Python 70.4%
  • PHP 16.4%
  • CSS 10.2%
  • Shell 1.9%
  • JavaScript 0.7%
  • Makefile 0.3%
  • VCL 0.1%