Skip to content

Commit 042deb7

Browse files
doc: updated readme / refactor: folders reorganized
1 parent 2a3d83b commit 042deb7

File tree

7 files changed

+32
-41
lines changed

7 files changed

+32
-41
lines changed

.gitignore

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1 @@
11
# Ignore this folders
2-
/db
3-
/plugins
4-
/themes

composer.json

Lines changed: 19 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,21 @@
11
{
2-
"name": "docker-env-template/wordpress-with-wp-cli",
3-
"description": "Basic Docker Wordpress Environment focused on development of plugins and themes, supports WP-CLI and phpMyAdmin",
4-
"homepage": "https://github.com/sarahcssiqueira/docker-wordpress-with-wp-cli",
5-
"license": "MIT",
6-
"keywords": [ "wordpress" , "docker-environment"],
7-
"authors": [
8-
{
9-
"name": "Sarah Siqueira",
10-
"email": "[email protected]",
11-
"homepage": "https://sarahjobs.com/"
12-
}
13-
],
14-
"type": "project",
15-
"require": {
16-
"php": ">=7.1.3"
2+
"name": "docker-env-template/wp-wp-cli",
3+
"description": "Docker WordPress Dev Environment, supports WP-CLI and phpMyAdmin",
4+
"homepage": "https://github.com/sarahcssiqueira/docker-wordpress-with-wp-cli",
5+
"license": "MIT",
6+
"keywords": [
7+
"wordpress",
8+
"docker-environment"
9+
],
10+
"authors": [
11+
{
12+
"name": "Sarah Siqueira",
13+
"email": "[email protected]",
14+
"homepage": "https://sarahjobs.com/"
1715
}
18-
}
16+
],
17+
"type": "project",
18+
"require": {
19+
"php": ">=7.1.3"
20+
}
21+
}
File renamed without changes.

docker-compose.yml renamed to docker/docker-compose.yml

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ services:
1212
MYSQL_PASSWORD: ${MYSQL_PASSWORD}
1313
MYSQL_RANDOM_ROOT_PASSWORD: 'root'
1414
volumes:
15-
- ./db:/var/lib/mysql
15+
- ../db:/var/lib/mysql
1616

1717

1818

@@ -45,8 +45,9 @@ services:
4545
WORDPRESS_DB_PASSWORD: ${MYSQL_PASSWORD}
4646
WORDPRESS_DB_NAME: ${MYSQL_DATABASE_NAME}
4747
volumes:
48-
- ./plugins:/var/www/html/wp-content/plugins
49-
- ./themes:/var/www/html/wp-content/themes
48+
- ../plugins:/var/www/html/wp-content/plugins
49+
- ../themes:/var/www/html/wp-content/themes
50+
5051

5152

5253

@@ -65,4 +66,4 @@ services:
6566
WORDPRESS_DB_NAME: ${MYSQL_DATABASE_NAME}
6667
user: xfs
6768
entrypoint: wp
68-
command: "--info"
69+
command: bash -c '--info'

plugins/.gitkeep

Whitespace-only changes.

readme.md

Lines changed: 8 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,43 +1,33 @@
11
# Docker WordPress Environment
22

3-
This is a basic **Docker WordPress Environment** focused on the development of **plugins and themes** (see volumes), supports [WP-CLI](https://wp-cli.org/) and [phpMyAdmin](https://www.phpmyadmin.net/).
3+
This is a basic **Docker WordPress Environment** focused on the development of **plugins and themes**, supports [WP-CLI](https://wp-cli.org/) and [phpMyAdmin](https://www.phpmyadmin.net/).
44

55
> **Disclaimer:** This project is meant to be used for development purposes only. It's **not** meant to be used in production.
66
77
> It's work in progress. Feel free to contribute if you have anything useful to add.
88
99
---
1010

11-
Clone this repository to your machine or download it through PHP Composer. To add through composer, add this code to your *composer.json* file in the root folder:
11+
## Usage
1212

13-
```
14-
"repositories": [
15-
{ "type": "vcs",
16-
"url": "[email protected]:sarahcssiqueira/docker-wordpress-with-wp-cli.git"
17-
}
18-
]
19-
```
20-
21-
Then run `composer require docker-env-template/wordpress-with-wp-cli`. This repository will be downloaded inside the vendor folder. Move it to the root.
22-
23-
Run `docker-compose up -d` to start your project.
13+
Clone this repository, then run run `docker-compose up -d` to start your project.
2414

2515
## Services
2616

27-
- db
17+
- **db**
2818

2919
The MYSQL official image
3020

31-
- phpMyAdmin
21+
- **phpMyAdmin**
3222

3323
Intended to handle the administration of MySQL, in this case through [localhost:8080/](localhost:8080/).
3424

35-
- WordPress
25+
- **WordPress**
3626

3727
Uses the official WordPress docker image
3828

39-
- WP-CLI
29+
- **WP-CLI**
4030

4131
The **wpcli container** was added in order to only run one-off commands. Don’t need it to run as a service, only as a cli tool, for that run:
4232

43-
`docker-compose run --rm wpcli command`
33+
`docker-compose run --rm wpcli command`

themes/.gitkeep

Whitespace-only changes.

0 commit comments

Comments
 (0)