GithubHelp home page GithubHelp logo

wp2ssl's Introduction

Buy Me a Coffee at ko-fi.com  

WP2SSL (WordPress 2 SSL): Move WordPress from HTTP to HTTPs. Automatically.

(c) 2017 Madalin Tache

A bash script that tries to automate the moving from HTTP to HTTPS, by doing most of the heavy lifting using WP-CLI.

What it does

It creates a backup of your current database first. It then replaces all instances of http with https on the current WordPress install, and updates .htaccess to force to HTTPS.

What it doesn't do (yet, or never)

It cannot update all theme/plugin files to be requested using HTTPS. If a plugin is using HTTP for the load, you will get mixed content warnings in your browser. If you're looking for a solution to these cases i suggest you check out Really Simple SSL

Installing

Install with:

curl -sSL https://wp2ssl-installer.includes.io | bash

Updating

If you want to update the script you can use two options. Either run the same command as the install (will auto-update if needed), or use the built-in updater

wp2ssl --up

or

wp2ssl --self-update

Using

For now, the plugin will only function if called from the main WordPress folder.

Use with:

cd /home/someuser/public_html
wp2ssl

Command Options

                  ____          _
   __      ___ __|___ \ ___ ___| |
   \ \ /\ / / '_ \ __) / __/ __| |
    \ V  V /| |_) / __/\__ \__ \ |
     \_/\_/ | .__/_____|___/___/_|
            |_|
                       v. 1.1
  https://github.com/niladam/wp2ssl

    [FLAGS]
        --up, --self-update         Self update this script to the latest version.
                                    Uses curl if available and fallsback to wget,
                                    if curl is missing.

        --h, --help                 This help screen.

Does it work ?

The script has been tested on a fresh WordPress install and it worked out of the box. So i guess YES !:)

Bugs ?

Found a bug ? Please use the isues section and report it. I'll be glad to tackle them.

Contributing

If you want to contribute to this script, please fork/clone create a new branch and use the pull requests. I'll be glad to see them coming.

TODO

  • Bulk run ?
  • Identify scripts/javascripts and force them to use HTTPS ?
  • Suggest and/or install Really Simple SSL after use?
  • Suggest and/or run backup before attempting the database changes ? Since #a854614 the plugin runs an export and archives the database dump. Just to be safe :)
  • Force WP-ADMIN SSL after run ?

Notes

Some of the functionality in this script were originally built for WPEB - WordPress Easy Backup, another script that might be of your interest.

License

WP2SSL (WordPress 2 SSL) is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 2 of the License, or (optionally) any later version.

wp2ssl's People

Contributors

niladam avatar

Stargazers

Alex Popescu avatar Mihai Popa avatar

Watchers

James Cloos avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.