コミットを比較
14 コミット
working
...
d6b50b7485
作成者 | SHA1 | 日付 | |
---|---|---|---|
d6b50b7485 | |||
7ced35ac8d | |||
7b56fd2488 | |||
9e176e921d | |||
73d38d46ba | |||
5f6f8d65e6 | |||
5caa4cac82 | |||
a534ceca03 | |||
423c803b69 | |||
b3b2f7abf0 | |||
591cff12c1 | |||
cd7cf577f3 | |||
7496125072 | |||
98c4098bf2 |
32
.gitignore
vendored
32
.gitignore
vendored
@ -1,28 +1,26 @@
|
|||||||
# Application
|
# Application
|
||||||
/bedrock/web/app/plugins/*
|
/src/web/app/plugins/*
|
||||||
/bedrock/!web/app/plugins/.gitkeep
|
/src/!web/app/plugins/.gitkeep
|
||||||
/bedrock/web/app/mu-plugins/*/
|
/src/web/app/mu-plugins/*
|
||||||
/bedrock/web/app/upgrade
|
/src/web/app/upgrade
|
||||||
/bedrock/web/app/uploads/*
|
/src/web/app/uploads/*
|
||||||
/bedrock/!web/app/uploads/.gitkeep
|
/src/!web/app/uploads/.gitkeep
|
||||||
|
|
||||||
# WordPress
|
# WordPress
|
||||||
/bedrock/web/wp
|
/src/web/wp
|
||||||
/bedrock/web/.htaccess
|
/src/web/.htaccess
|
||||||
|
|
||||||
# Logs
|
# Logs
|
||||||
*.log
|
/src/**/*.log
|
||||||
|
|
||||||
# Dotenv
|
# Dotenv
|
||||||
.env
|
/src/.env
|
||||||
.env.*
|
/src/.env.*
|
||||||
!.env.example
|
!/src/.env.example
|
||||||
/bedrock/.env
|
!/src/.env.sample
|
||||||
/bedrock/.env.*
|
|
||||||
/bedrock/!.env.example
|
|
||||||
|
|
||||||
# Composer
|
# Composer
|
||||||
/bedrock/vendor
|
/src/vendor
|
||||||
|
|
||||||
# WP-CLI
|
# WP-CLI
|
||||||
wp-cli.local.yml
|
/src/wp-cli.local.yml
|
||||||
|
@ -1,7 +0,0 @@
|
|||||||
FROM php:8.0-apache
|
|
||||||
|
|
||||||
COPY entrypoint-wordpress.sh /usr/local/bin/
|
|
||||||
|
|
||||||
COPY apache-docker.conf /etc/apache2/sites-enabled/
|
|
||||||
|
|
||||||
ENTRYPOINT /usr/local/bin/entrypoint-wordpress.sh
|
|
10
README.md
ノーマルファイル
10
README.md
ノーマルファイル
@ -0,0 +1,10 @@
|
|||||||
|
# wordpress-bedrock-docker
|
||||||
|
|
||||||
|
A template for a Wordpress site using Bedrock (Composer) + Docker.
|
||||||
|
|
||||||
|
## Quick start
|
||||||
|
|
||||||
|
1. Create a new repository in Gitea, using this repository as a template
|
||||||
|
2. Clone the new repository
|
||||||
|
3. Copy `src/.env.example` to `src/.env`
|
||||||
|
4. Run `docker-compose up`
|
@ -1,17 +0,0 @@
|
|||||||
<VirtualHost *:80>
|
|
||||||
|
|
||||||
ServerName localhost
|
|
||||||
|
|
||||||
ServerAdmin webmaster@localhost
|
|
||||||
DocumentRoot /var/www/html/web
|
|
||||||
|
|
||||||
ErrorLog /var/log/apache2/error.log
|
|
||||||
CustomLog /var/log/apache2/access.log combined
|
|
||||||
|
|
||||||
<Directory /var/www/html>
|
|
||||||
Options Indexes FollowSymLinks
|
|
||||||
AllowOverride All
|
|
||||||
Require all granted
|
|
||||||
</Directory>
|
|
||||||
|
|
||||||
</VirtualHost>
|
|
5489
bedrock/composer.lock
generated
5489
bedrock/composer.lock
generated
ファイル差分が大きすぎるため省略します
差分を読み込み
@ -1,16 +0,0 @@
|
|||||||
<?php
|
|
||||||
/**
|
|
||||||
* Plugin Name: Bedrock Autoloader
|
|
||||||
* Plugin URI: https://github.com/roots/bedrock-autoloader
|
|
||||||
* Description: An autoloader that enables standard plugins to be required just like must-use plugins. The autoloaded plugins are included during mu-plugin loading. An asterisk (*) next to the name of the plugin designates the plugins that have been autoloaded.
|
|
||||||
* Version: 1.0.3
|
|
||||||
* Author: Roots
|
|
||||||
* Author URI: https://roots.io/
|
|
||||||
* License: MIT License
|
|
||||||
*/
|
|
||||||
|
|
||||||
namespace Roots\Bedrock;
|
|
||||||
|
|
||||||
if (is_blog_installed() && class_exists(Autoloader::class)) {
|
|
||||||
new Autoloader();
|
|
||||||
}
|
|
@ -1,14 +0,0 @@
|
|||||||
<?php
|
|
||||||
/**
|
|
||||||
* Plugin Name: Register Theme Directory
|
|
||||||
* Plugin URI: https://github.com/roots/bedrock/
|
|
||||||
* Description: Register default theme directory
|
|
||||||
* Version: 1.0.0
|
|
||||||
* Author: Roots
|
|
||||||
* Author URI: https://roots.io/
|
|
||||||
* License: MIT License
|
|
||||||
*/
|
|
||||||
|
|
||||||
if (!defined('WP_DEFAULT_THEME')) {
|
|
||||||
register_theme_directory(ABSPATH . 'wp-content/themes');
|
|
||||||
}
|
|
@ -1,27 +1,25 @@
|
|||||||
---
|
---
|
||||||
version: "3"
|
version: '3.1'
|
||||||
|
|
||||||
services:
|
services:
|
||||||
wordpress:
|
web:
|
||||||
image: "thecoopcloud/wordpress:5.8.2-php7.4"
|
image: nginx:alpine
|
||||||
build: .
|
working_dir: /app
|
||||||
ports:
|
ports:
|
||||||
- "80:80"
|
- "80:80"
|
||||||
volumes:
|
volumes:
|
||||||
- "./bedrock/:/var/www/html/"
|
- ./nginx.conf:/etc/nginx/conf.d/default.conf:cached
|
||||||
- "./entrypoint-wordpress.sh:/usr/local/bin/entrypoint-wordpress.sh"
|
- ./src:/app:cached
|
||||||
environment:
|
|
||||||
- WORDPRESS_DB_HOST=db
|
php:
|
||||||
- WORDPRESS_DB_USER=wordpress
|
image: "thecoopcloud/wordpress:5.8.2-php7.4-fpm-bedrock"
|
||||||
- WORDPRESS_DB_PASSWORD=wordpress
|
working_dir: /app
|
||||||
- WORDPRESS_DB_NAME=wordpress
|
user: 1000:1000
|
||||||
- WORDPRESS_CONFIG_EXTRA=${WORDPRESS_CONFIG_EXTRA}
|
volumes:
|
||||||
- WORDPRESS_DEBUG=${WORDPRESS_DEBUG}
|
- ./src:/app:cached
|
||||||
- PHP_EXTENSIONS
|
|
||||||
container_name: "${PROJECT_NAME}_wordpress"
|
|
||||||
|
|
||||||
db:
|
db:
|
||||||
image: "mariadb:10.6"
|
image: mariadb:10.4
|
||||||
volumes:
|
volumes:
|
||||||
- "mariadb:/var/lib/mysql"
|
- "mariadb:/var/lib/mysql"
|
||||||
environment:
|
environment:
|
||||||
@ -29,10 +27,6 @@ services:
|
|||||||
- MYSQL_DATABASE=wordpress
|
- MYSQL_DATABASE=wordpress
|
||||||
- MYSQL_USER=wordpress
|
- MYSQL_USER=wordpress
|
||||||
- MYSQL_PASSWORD=wordpress
|
- MYSQL_PASSWORD=wordpress
|
||||||
container_name: "${PROJECT_NAME}_db"
|
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
mariadb:
|
mariadb:
|
||||||
|
|
||||||
networks:
|
|
||||||
backend:
|
|
||||||
|
@ -1,15 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
if [ -n "$PHP_EXTENSIONS" ]; then
|
|
||||||
docker-php-ext-install "$PHP_EXTENSIONS"
|
|
||||||
fi
|
|
||||||
|
|
||||||
chown -R www-data:www-data /var/www/html
|
|
||||||
|
|
||||||
if [ -n "$*" ]; then
|
|
||||||
"$@"
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Upstream ENTRYPOINT
|
|
||||||
# https://github.com/docker-library/wordpress/blob/master/php7.4/apache/Dockerfile#L120
|
|
||||||
apache2-foreground
|
|
48
nginx.conf
ノーマルファイル
48
nginx.conf
ノーマルファイル
@ -0,0 +1,48 @@
|
|||||||
|
server {
|
||||||
|
listen 80 default_server;
|
||||||
|
listen [::]:80 default_server;
|
||||||
|
|
||||||
|
server_name _;
|
||||||
|
|
||||||
|
client_max_body_size 128M;
|
||||||
|
|
||||||
|
gzip on;
|
||||||
|
gzip_proxied any;
|
||||||
|
gzip_types text/plain text/xml text/css application/x-javascript;
|
||||||
|
gzip_vary on;
|
||||||
|
gzip_disable "MSIE [1-6]\.(?!.*SV1)";
|
||||||
|
|
||||||
|
sendfile on;
|
||||||
|
sendfile_max_chunk 512k;
|
||||||
|
|
||||||
|
root /app/web;
|
||||||
|
|
||||||
|
access_log off;
|
||||||
|
|
||||||
|
location / {
|
||||||
|
include /etc/nginx/mime.types;
|
||||||
|
|
||||||
|
root /app/web;
|
||||||
|
index index.html index.htm index.php;
|
||||||
|
|
||||||
|
try_files $uri $uri/ /index.php?q=$uri&$args;
|
||||||
|
}
|
||||||
|
|
||||||
|
location ~ .php$ {
|
||||||
|
include fastcgi.conf;
|
||||||
|
|
||||||
|
fastcgi_read_timeout 300;
|
||||||
|
fastcgi_pass php:9000;
|
||||||
|
|
||||||
|
fastcgi_index index.php;
|
||||||
|
fastcgi_param SCRIPT_FILENAME /app/web/$fastcgi_script_name;
|
||||||
|
fastcgi_param PATH_INFO $fastcgi_script_name;
|
||||||
|
|
||||||
|
fastcgi_param PHP_VALUE "error_log=/var/log/nginx/application_php_errors.log";
|
||||||
|
fastcgi_buffers 16 16k;
|
||||||
|
fastcgi_buffer_size 32k;
|
||||||
|
|
||||||
|
include fastcgi_params;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
@ -1,17 +1,17 @@
|
|||||||
DB_NAME='database_name'
|
DB_NAME='wordpress'
|
||||||
DB_USER='database_user'
|
DB_USER='wordpress'
|
||||||
DB_PASSWORD='database_password'
|
DB_PASSWORD='wordpress'
|
||||||
|
|
||||||
# Optionally, you can use a data source name (DSN)
|
# Optionally, you can use a data source name (DSN)
|
||||||
# When using a DSN, you can remove the DB_NAME, DB_USER, DB_PASSWORD, and DB_HOST variables
|
# When using a DSN, you can remove the DB_NAME, DB_USER, DB_PASSWORD, and DB_HOST variables
|
||||||
# DATABASE_URL='mysql://database_user:database_password@database_host:database_port/database_name'
|
# DATABASE_URL='mysql://database_user:database_password@database_host:database_port/database_name'
|
||||||
|
|
||||||
# Optional database variables
|
# Optional database variables
|
||||||
# DB_HOST='localhost'
|
DB_HOST='db'
|
||||||
# DB_PREFIX='wp_'
|
# DB_PREFIX='wp_'
|
||||||
|
|
||||||
WP_ENV='development'
|
WP_ENV='development'
|
||||||
WP_HOME='http://example.com'
|
WP_HOME='http://localhost'
|
||||||
WP_SITEURL="${WP_HOME}/wp"
|
WP_SITEURL="${WP_HOME}/wp"
|
||||||
|
|
||||||
# Specify optional debug.log path
|
# Specify optional debug.log path
|
@ -39,8 +39,7 @@
|
|||||||
"roots/bedrock-disallow-indexing": "^2.0",
|
"roots/bedrock-disallow-indexing": "^2.0",
|
||||||
"roots/wordpress": "5.8.2",
|
"roots/wordpress": "5.8.2",
|
||||||
"roots/wp-config": "1.0.0",
|
"roots/wp-config": "1.0.0",
|
||||||
"roots/wp-password-bcrypt": "1.1.0",
|
"roots/wp-password-bcrypt": "1.1.0"
|
||||||
"wp-cli/wp-cli-bundle": "^2.5"
|
|
||||||
},
|
},
|
||||||
"require-dev": {
|
"require-dev": {
|
||||||
"squizlabs/php_codesniffer": "^3.6.0",
|
"squizlabs/php_codesniffer": "^3.6.0",
|
1472
src/composer.lock
generated
ノーマルファイル
1472
src/composer.lock
generated
ノーマルファイル
ファイル差分が大きすぎるため省略します
差分を読み込み
新しいイシューから参照
ユーザーをブロックする