forked from wp-net/wordpress-docker-compose
-
Notifications
You must be signed in to change notification settings - Fork 0
/
README.Rmd
76 lines (49 loc) · 2.22 KB
/
README.Rmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
---
output: github_document
---
<!-- README.md is generated from README.Rmd. Please edit that file -->
```{r, include = FALSE}
knitr::opts_chunk$set(
collapse = TRUE,
comment = "#>"
)
```
# Deploy Wordpress on Localhost and in Production using Docker Compose
Related blog post:
- [WordPress Local Development Using Docker Compose](https://www.datanovia.com/en/lessons/wordpress-local-development-using-docker-compose/): Deploy Wordpress on localhost using docker
- [Docker WordPress Production Deployment](https://www.datanovia.com/en/lessons/docker-wordpress-production-deployment/): Step-by-step guide to deploy WordPress online using docker-compose
- [Using Docker WordPress Cli to Manage WordPress Websites](https://www.datanovia.com/en/lessons/using-docker-wordpress-cli-to-manage-wordpress-websites/): Commande line interface for managing a WordPress website
The installation tool kit, provided here, include:
- Nginx web server
- MariaDB/MySQL used for Wordpress database
- phpMyAdmin interface to connect to your MySQL database
- WP-Cli: Wordpress Command Line Interface
- Makefile directives for automatization.
You can automatically deploy a local docker wordpress site in 5 minutes using the following commands:
```bash
# Download a wordpress docker-compose example
git clone https://github.com/kassambara/wordpress-docker-compose
cd wordpress-docker-compose
# Build and start installation
docker-compose up -d --build
```
Visit your site at http://localhost and your database via phpMyAdmin at http://localhost:8080.
Default identification for your wordpress website admin:
- `Username: wordpress` and
- `Password: wordpress`
Default identification for the phpMyAdmin interface:
- `Username: root` and
- `Password: password`
**Useful set of commands to know**:
```bash
# Stop and remove containers
docker-compose down
# Build, and start the wordpress website
docker-compose up -d --build
# Reset everything
docker-compose down
rm -rf certs/* certs-data/* logs/nginx/* mysql/* wordpress/*
```
## References
- [WordPress: with Nginx web server in Docker](https://github.com/mjstealey/wordpress-nginx-docker)
- [Quickstart: Compose and WordPress](https://docs.docker.com/compose/wordpress/)