All Projects → pothi → wp-in-a-box

pothi / wp-in-a-box

Licence: GPL-2.0 license
WordPress in a (LEMP) box (Debian & Ubuntu)!

Programming Languages

shell
77523 projects

Projects that are alternatives of or similar to wp-in-a-box

Wordops
Install and manage a high performance WordPress stack with a few keystrokes
Stars: ✭ 649 (+1124.53%)
Mutual labels:  debian, lemp
Slickstack
SlickStack is a free LEMP stack automation script written in Bash designed to enhance and simplify WordPress provisioning, performance, and security.
Stars: ✭ 311 (+486.79%)
Mutual labels:  debian, lemp
dotfiles
Dotfiles generator that allows quick configuration of different window managers in multiple OSs
Stars: ✭ 36 (-32.08%)
Mutual labels:  debian
debian900
DebiaN900 - A set of scripts to facilitate the installation of Devuan or Debian GNU/Linux on the Nokia N900
Stars: ✭ 35 (-33.96%)
Mutual labels:  debian
installer-linux
💾 SinusBot Installer for Debian, Ubuntu and CentOS - Installs the SinusBot with a single command.
Stars: ✭ 28 (-47.17%)
Mutual labels:  debian
ansible-role-php-versions
Ansible Role - PHP Versions
Stars: ✭ 78 (+47.17%)
Mutual labels:  debian
debian-packaging
Create Debian packages of non-free, closed-source and other software.
Stars: ✭ 19 (-64.15%)
Mutual labels:  debian
scripts
Collection of useful scripts for Linux (git, docker, LUKS, Archlinux...)
Stars: ✭ 36 (-32.08%)
Mutual labels:  debian
wakemeops
A Debian repository for portable applications
Stars: ✭ 54 (+1.89%)
Mutual labels:  debian
python-deb-pkg-tools
Debian packaging tools
Stars: ✭ 36 (-32.08%)
Mutual labels:  debian
sarbian
We’ve built a plug’n play Operation System (based on Debian Linux) with all the freely and openly available SAR processing software. No knowledge of installation steps needed, just download and get started with SAR data processing. SARbian is free for use in research, education or operational work.
Stars: ✭ 49 (-7.55%)
Mutual labels:  debian
Deb Dots
Debian GNU/Linux dot files.
Stars: ✭ 49 (-7.55%)
Mutual labels:  debian
builder
Treehouses Awesome 👓 Raspberry Pi Image Builder 🏗
Stars: ✭ 44 (-16.98%)
Mutual labels:  debian
install script
YunoHost installation scripts
Stars: ✭ 71 (+33.96%)
Mutual labels:  debian
ezpptp
Easy PPTP VPN setup script for Debian based VPS
Stars: ✭ 87 (+64.15%)
Mutual labels:  debian
cylon-deb
TUI menu driven bash shell script to update and maintain a Debian based Linux distro.
Stars: ✭ 23 (-56.6%)
Mutual labels:  debian
debian bridge
CLI utility to run .deb packages on non-debian distros using docker
Stars: ✭ 23 (-56.6%)
Mutual labels:  debian
task-spooler
A scheduler for GPU/CPU tasks
Stars: ✭ 77 (+45.28%)
Mutual labels:  debian
debian-setup
neurite.github.io/debian-setup
Stars: ✭ 27 (-49.06%)
Mutual labels:  debian
my blog
在 Issues 中建立的个人博客
Stars: ✭ 28 (-47.17%)
Mutual labels:  debian

WP In A Box

Script/s to install LEMP in a linux box. This LEMP stack is fine-tuned towards WordPress installations. It may work for other PHP based applications, too. For more details, please see the blog post at https://www.tinywp.in/wp-in-a-box/.

There are a number of similar scripts available on the internet. The unique feature of this repo is in security considerations.

Supported Platforms

  • Ubuntu Focal Fossa (20.04.x)
  • Ubuntu Bionic Beaver (18.04.x)
  • Debian Stretch (9.x)
  • Ubuntu Xenial Xerus (16.04.x)

Generic Goals

In sync with WordPress philosophy of “decision, not options”.

Performance Considerations

  • No added bloatware
  • Redis for object cache (available as an optional package)
  • Full page cache support (WP Super Cache, WP Rocket and WP Fastest Cache)
  • PHP 7.x
  • Nginx (no Apache, sorry)
  • Varnish (planned, but no ETA)
  • Swap

Security Considerations

  • No phoning home.
  • No external dependencies (such as third-party repositories, unless there is a strong reason to use it).
  • Automatic security updates (with an option to update everything).
  • Disable password authentication for root.
  • Nginx (possibly with Naxsi WAF when h2 issue is resolved).
  • Umask 027 or 077.
  • ACL integration.
  • Weekly logwatch (if email is supplied).
  • Isolated user for PhpMyAdmin.
  • PHP user and Nginx user run under different username.
  • Only ports 80, 443, and port for SSH are open.

Implementation Details

  • Agentless.
  • Idempotent.
  • Random username (like GoDaddy generates).
  • Automatic restart of MySQL (and Varnish) upon failure.
  • Integrated wp-cli.
  • Support for version control (git, hg).
  • Composer pre-installed.
  • Auto-update of almost everything (wp-cli, composer, certbot certs, etc).

Roadmap

  • Automatic Certbot / LetsEncrypt installation and renewal (like Caddy).
  • Automated setup of sites using backups.
  • Web interface (planned, but no ETA).
  • Automatic backup of site/s (files and DB) to AWS S3 or to GCP.

Install procedure

  • Rename .envrc-sample file as .envrc and insert as much information as possible
  • Download bootstrap.sh and execute it.
# as root

apt install curl screen -y

# optional steps
# curl -LO https://github.com/pothi/wp-in-a-box/raw/main/.envrc-sample
# cp .envrc-sample .envrc
# nano .envrc

# download the bootstrap script
curl -LO https://github.com/pothi/wp-in-a-box/raw/main/bootstrap.sh

# please do not trust any script on the internet or github
# so, please go through it!
nano ~/bootstrap.sh

# execute it and wait for some time
# screen bash bootstrap.sh
# or simply
bash bootstrap.sh

# wait for the installation to get over.
# it can take approximately 5 minutes on a 2GB server
# it depends on CPU power too

# we no longer needs bootstrap.sh file
rm bootstrap.sh

# to see the credentials to log in to the server from now
# this is the important step. you can't login as root from now on
cat ~/.envrc

What you get at the end of the installation

You may find the following details at ~/.envrc file...

  • a SSH user (prefixed with ssh_) with sudo privileges (use it only to manage the server such as to create a new MySQL database or to create a new vhost entry for Nginx)
  • a chrooted SFTP user, prefixed with sftp_web_, with its home directory at /home/web along with some common directories(such as ~/log, ~/sites, etc) created already. (you may give it to your developer to access the file system such as to upload a new theme, etc)
  • a dedicated MySQL username (and password) with all the privileges as root user. This can be used to access MySQL via PhpMyAdmin, as root user can only access MySQL via cli.

Where to install WordPress & How to install it

  • PHP runs as SFTP user. So, please install WordPress as SFTP user at /home/web/sites/example.com/public.
  • Configure Nginx using pre-defined templates that can be found at the companion repo WordPress-Nginx. That repo is already installed. You just have to copy / paste one of the templates to fit your domain name.
  • If you wish to deploy SSL, a Let's Encrypt client is already installed. Please use the command certbot certonly --webroot -w /home/web/sites/example.com/public -d example.com -d www.example.com. The renewal script is already in place as a cron entry. So, you don't have to create a new entry. To know more about this client library and to know more about the available options, please visit https://certbot.eff.org/ .

Known Limitations

  • SFTP user can not create or upload new files and folders at $HOME, but can create or upload inside other existing directories. This is a known limitation when we use SFTP capability of built-in OpenSSH server.

Wiki

For more documentation, information, supported/tested hosts, todo, etc, please see the WP-In-A-Box wiki.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].