mirror of
https://github.com/10h30/kazewp.git
synced 2026-05-12 15:21:20 +09:00
Update README.md & reload_caddy
This commit is contained in:
@@ -28,8 +28,8 @@ Ensure you have the following installed:
|
||||
|
||||
1. **Clone the repository**:
|
||||
```bash
|
||||
git clone https://github.com/your-username/CaddyWP.git
|
||||
cd CaddyWP
|
||||
git clone https://github.com/your-username/caddywp.git
|
||||
cd caddywp
|
||||
```
|
||||
|
||||
2. **Run the install script**:
|
||||
@@ -40,7 +40,9 @@ Ensure you have the following installed:
|
||||
## How It Works
|
||||
|
||||
Caddy: Serves as a reverse proxy, automatically obtaining SSL certificates and routing traffic to the correct WordPress container.
|
||||
|
||||
WordPress: Each WordPress site is hosted in its own Docker container, ensuring that each site runs in isolation with its own environment and database.
|
||||
|
||||
MariaDB: A single MariaDB container serves as the database for all WordPress sites. Each site uses a unique database user and password.
|
||||
|
||||
## License
|
||||
|
||||
@@ -87,6 +87,7 @@ while true; do
|
||||
echo "1. Start Caddy:"
|
||||
echo " cd ${CADDY_DIR} && docker compose up -d"
|
||||
fi
|
||||
reload_caddy
|
||||
echo "2. Start WordPress:"
|
||||
echo " cd ${WP_PROJECT_DIR} && docker compose up -d"
|
||||
echo "3. Run the WordPress setup script:"
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@
|
||||
|
||||
reload_caddy() {
|
||||
echo "Reloading Caddy configuration..."
|
||||
docker exec caddy caddy reload --config /etc/caddy/Caddyfile
|
||||
cd "$CADDY_DIR" && docker compose restart
|
||||
}
|
||||
|
||||
create_caddy_config() {
|
||||
|
||||
@@ -1,13 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
wp_cli() {
|
||||
docker run --rm \
|
||||
--network container:wordpress_${DOMAIN} \
|
||||
-v "$(pwd):/var/www/html" \
|
||||
wordpress:cli-php8.1 \
|
||||
wp "$@"
|
||||
}
|
||||
|
||||
wpcli() {
|
||||
docker compose run --rm wpcli "$@"
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user