Skip to content

Commit 6b5a416

Browse files
authored
README (#411)
Add Readme
1 parent 942384a commit 6b5a416

File tree

1 file changed

+121
-0
lines changed

1 file changed

+121
-0
lines changed

README.md

Lines changed: 121 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,121 @@
1+
# VIP Codespaces
2+
3+
A development environment for WordPress VIP sites using GitHub Codespaces and VS Code Development Containers.
4+
5+
## Overview
6+
7+
VIP Codespaces provides a containerized development environment for WordPress VIP sites, making it easy to set up and maintain a consistent development environment across teams. It leverages GitHub Codespaces and VS Code (and forks) [Development Containers](https://containers.dev/) to provide a seamless development experience.
8+
9+
## Features
10+
11+
- **WordPress Development Environment**: Pre-configured with WordPress, MariaDB, Nginx, and PHP
12+
- **WordPress Integration**: Includes VIP Go mu-plugins and VIP CLI
13+
- **Development Tools**: Includes tools like WP-CLI, XDebug, phpMyAdmin, and Mailpit
14+
- **Customizable**: Configure PHP version, WordPress version, and other settings
15+
- **Elasticsearch Support**: Optional Elasticsearch integration
16+
- **Memcached Support**: Optional Memcached integration
17+
- **Cron Support**: Configurable WordPress cron jobs
18+
19+
## Getting Started
20+
21+
### Prerequisites
22+
23+
- GitHub account with access to GitHub Codespaces
24+
- OR other IDEs supporting Dev Containers
25+
26+
### Using with GitHub Codespaces
27+
28+
1. We provide the `.devcontainer/devcontainer.json` in our [Skeleton template repository](https://github.com/Automattic/vip-go-skeleton/tree/production/.devcontainer). For older codebases, you will need to add the `.devcontainer/devcontainer.json` configuration to your WordPress VIP repository manually
29+
2. Start a new Codespace from your repository
30+
3. Wait for the environment to build and initialize
31+
4. Access your WordPress site at the forwarded port (typically port 80)
32+
33+
34+
### Using with VS Code/Cursor/Windsurf Development Containers
35+
36+
1. Add the `.devcontainer/devcontainer.json` configuration to your WordPress VIP project
37+
2. Open the project in VS Code
38+
3. Click on the Remote Containers extension icon and select "Reopen in Container"
39+
4. Wait for the environment to build and initialize
40+
5. Access your WordPress site at localhost
41+
42+
## Configuration
43+
44+
The development environment can be customized through the `devcontainer.json` file. Available options include:
45+
46+
- PHP version
47+
- WordPress version
48+
- WordPress domain
49+
- WordPress multisite configuration
50+
- VIP Go mu-plugins integration
51+
- Development tools (Xdebug, phpMyAdmin, Mailpit, etc.)
52+
- Elasticsearch and Memcached support
53+
- Cron configuration
54+
55+
Example configuration:
56+
57+
```json
58+
{
59+
"name": "WordPress VIP Development Environment",
60+
"image": "ghcr.io/automattic/vip-codespaces/alpine-base:latest",
61+
"features": {
62+
"ghcr.io/automattic/vip-codespaces/nginx:latest": {},
63+
"ghcr.io/automattic/vip-codespaces/php:latest": {
64+
"version": "8.0"
65+
},
66+
"ghcr.io/automattic/vip-codespaces/mariadb:latest": {},
67+
"ghcr.io/automattic/vip-codespaces/wordpress:latest": {
68+
"version": "latest",
69+
"multisite": "false"
70+
},
71+
"ghcr.io/automattic/vip-codespaces/vip-go-mu-plugins:latest": {
72+
"enabled": "true"
73+
}
74+
}
75+
}
76+
```
77+
78+
## Available Features
79+
80+
The environment is built using a modular approach with various features that can be enabled or disabled:
81+
82+
- **base**: Base feature for VIP Codespaces
83+
- **nginx**: Nginx web server
84+
- **php**: PHP with configurable version
85+
- **mariadb**: MariaDB database server
86+
- **wordpress**: WordPress core
87+
- **wp-cli**: WordPress CLI
88+
- **vip-go-mu-plugins**: WordPress VIP MY-plugins
89+
- **vip-cli**: VIP CLI
90+
- **elasticsearch**: Elasticsearch server
91+
- **memcached**: Memcached server
92+
- **xdebug**: Xdebug for PHP debugging
93+
- **phpmyadmin**: phpMyAdmin for database management
94+
- **mailpit**: Mail testing tool
95+
- **cron**: Cron job support
96+
97+
## Port Forwarding
98+
99+
The environment forwards several ports for accessing different services:
100+
101+
- **80**: WordPress application
102+
- **81**: phpMyAdmin
103+
- **8025**: Mailpit web interface
104+
- **9003**: Xdebug
105+
106+
## Contributing
107+
108+
Contributions to VIP Codespaces are welcome. Please follow the standard GitHub workflow:
109+
110+
1. Fork the repository
111+
2. Create a feature branch
112+
3. Make your changes
113+
4. Submit a pull request
114+
115+
## License
116+
117+
This project is licensed under the terms of the GPL v2+ license.
118+
119+
## Support
120+
121+
For support with VIP Codespaces, please open an issue on the GitHub repository.

0 commit comments

Comments
 (0)