Skip to content
This repository was archived by the owner on May 26, 2023. It is now read-only.

Commit 0173b36

Browse files
Merge pull request #2 from studiometa/feature/v2
[Feature] v2
2 parents 88b2cfc + d1ed125 commit 0173b36

File tree

133 files changed

+34910
-1716
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

133 files changed

+34910
-1716
lines changed

.ddev/config.yaml

Lines changed: 260 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,260 @@
1+
name: wordpress-project
2+
type: wordpress
3+
docroot: web
4+
php_version: "7.3"
5+
webserver_type: apache-fpm
6+
router_http_port: "80"
7+
router_https_port: "443"
8+
xdebug_enabled: false
9+
additional_hostnames: []
10+
additional_fqdns: []
11+
database:
12+
type: mariadb
13+
version: "10.3"
14+
nfs_mount_enabled: false
15+
mutagen_enabled: false
16+
use_dns_when_possible: true
17+
composer_version: "2"
18+
disable_settings_management: true
19+
web_environment: []
20+
nodejs_version: "16"
21+
22+
# Key features of ddev's config.yaml:
23+
24+
# name: <projectname> # Name of the project, automatically provides
25+
# http://projectname.ddev.site and https://projectname.ddev.site
26+
27+
# type: <projecttype> # drupal6/7/8, backdrop, typo3, wordpress, php
28+
29+
# docroot: <relative_path> # Relative path to the directory containing index.php.
30+
31+
# php_version: "7.4" # PHP version to use, "5.6", "7.0", "7.1", "7.2", "7.3", "7.4", "8.0", "8.1"
32+
33+
# You can explicitly specify the webimage but this
34+
# is not recommended, as the images are often closely tied to ddev's' behavior,
35+
# so this can break upgrades.
36+
37+
# webimage: <docker_image> # nginx/php docker image.
38+
39+
# database:
40+
# type: <dbtype> # mysql, mariadb
41+
# version: <version> # database version, like "10.3" or "8.0"
42+
# Note that mariadb_version or mysql_version from v1.18 and earlier
43+
# will automatically be converted to this notation with just a "ddev config --auto"
44+
45+
# router_http_port: <port> # Port to be used for http (defaults to port 80)
46+
# router_https_port: <port> # Port for https (defaults to 443)
47+
48+
# xdebug_enabled: false # Set to true to enable xdebug and "ddev start" or "ddev restart"
49+
# Note that for most people the commands
50+
# "ddev xdebug" to enable xdebug and "ddev xdebug off" to disable it work better,
51+
# as leaving xdebug enabled all the time is a big performance hit.
52+
53+
# xhprof_enabled: false # Set to true to enable xhprof and "ddev start" or "ddev restart"
54+
# Note that for most people the commands
55+
# "ddev xhprof" to enable xhprof and "ddev xhprof off" to disable it work better,
56+
# as leaving xhprof enabled all the time is a big performance hit.
57+
58+
# webserver_type: nginx-fpm # or apache-fpm
59+
60+
# timezone: Europe/Berlin
61+
# This is the timezone used in the containers and by PHP;
62+
# it can be set to any valid timezone,
63+
# see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
64+
# For example Europe/Dublin or MST7MDT
65+
66+
# composer_root: <relative_path>
67+
# Relative path to the composer root directory from the project root. This is
68+
# the directory which contains the composer.json and where all Composer related
69+
# commands are executed.
70+
71+
# composer_version: "2"
72+
# You can set it to "" or "2" (default) for Composer v2 or "1" for Composer v1
73+
# to use the latest major version available at the time your container is built.
74+
# It is also possible to select a minor version for example "2.2" which will
75+
# install the latest release of that branch. Alternatively, an explicit Composer
76+
# version may be specified, for example "1.0.22". Finally, it is also possible
77+
# to use one of the key words "stable", "preview" or "snapshot" see Composer
78+
# documentation.
79+
# To reinstall Composer after the image was built, run "ddev debug refresh".
80+
81+
# nodejs_version: "16"
82+
# change from the default system Node.js version to another supported version, like 12, 14, 17, 18.
83+
# Note that you can use 'ddev nvm' or nvm inside the web container to provide nearly any
84+
# Node.js version, including v6, etc.
85+
86+
# additional_hostnames:
87+
# - somename
88+
# - someothername
89+
# would provide http and https URLs for "somename.ddev.site"
90+
# and "someothername.ddev.site".
91+
92+
# additional_fqdns:
93+
# - example.com
94+
# - sub1.example.com
95+
# would provide http and https URLs for "example.com" and "sub1.example.com"
96+
# Please take care with this because it can cause great confusion.
97+
98+
# upload_dir: custom/upload/dir
99+
# would set the destination path for ddev import-files to <docroot>/custom/upload/dir
100+
# When mutagen is enabled this path is bind-mounted so that all the files
101+
# in the upload_dir don't have to be synced into mutagen
102+
103+
# working_dir:
104+
# web: /var/www/html
105+
# db: /home
106+
# would set the default working directory for the web and db services.
107+
# These values specify the destination directory for ddev ssh and the
108+
# directory in which commands passed into ddev exec are run.
109+
110+
# omit_containers: [db, dba, ddev-ssh-agent]
111+
# Currently only these containers are supported. Some containers can also be
112+
# omitted globally in the ~/.ddev/global_config.yaml. Note that if you omit
113+
# the "db" container, several standard features of ddev that access the
114+
# database container will be unusable. In the global configuration it is also
115+
# possible to omit ddev-router, but not here.
116+
117+
# nfs_mount_enabled: false
118+
# Great performance improvement but requires host configuration first.
119+
# See https://ddev.readthedocs.io/en/stable/users/performance/#using-nfs-to-mount-the-project-into-the-container
120+
121+
# mutagen_enabled: false
122+
# Performance improvement using mutagen asynchronous updates.
123+
# See https://ddev.readthedocs.io/en/latest/users/performance/#using-mutagen
124+
125+
# fail_on_hook_fail: False
126+
# Decide whether 'ddev start' should be interrupted by a failing hook
127+
128+
# host_https_port: "59002"
129+
# The host port binding for https can be explicitly specified. It is
130+
# dynamic unless otherwise specified.
131+
# This is not used by most people, most people use the *router* instead
132+
# of the localhost port.
133+
134+
# host_webserver_port: "59001"
135+
# The host port binding for the ddev-webserver can be explicitly specified. It is
136+
# dynamic unless otherwise specified.
137+
# This is not used by most people, most people use the *router* instead
138+
# of the localhost port.
139+
140+
# host_db_port: "59002"
141+
# The host port binding for the ddev-dbserver can be explicitly specified. It is dynamic
142+
# unless explicitly specified.
143+
144+
# phpmyadmin_port: "8036"
145+
# phpmyadmin_https_port: "8037"
146+
# The PHPMyAdmin ports can be changed from the default 8036 and 8037
147+
148+
# host_phpmyadmin_port: "8036"
149+
# The phpmyadmin (dba) port is not normally bound on the host at all, instead being routed
150+
# through ddev-router, but it can be specified and bound.
151+
152+
# mailhog_port: "8025"
153+
# mailhog_https_port: "8026"
154+
# The MailHog ports can be changed from the default 8025 and 8026
155+
156+
# host_mailhog_port: "8025"
157+
# The mailhog port is not normally bound on the host at all, instead being routed
158+
# through ddev-router, but it can be bound directly to localhost if specified here.
159+
160+
# webimage_extra_packages: [php7.4-tidy, php-bcmath]
161+
# Extra Debian packages that are needed in the webimage can be added here
162+
163+
# dbimage_extra_packages: [telnet,netcat]
164+
# Extra Debian packages that are needed in the dbimage can be added here
165+
166+
# use_dns_when_possible: true
167+
# If the host has internet access and the domain configured can
168+
# successfully be looked up, DNS will be used for hostname resolution
169+
# instead of editing /etc/hosts
170+
# Defaults to true
171+
172+
# project_tld: ddev.site
173+
# The top-level domain used for project URLs
174+
# The default "ddev.site" allows DNS lookup via a wildcard
175+
# If you prefer you can change this to "ddev.local" to preserve
176+
# pre-v1.9 behavior.
177+
178+
# ngrok_args: --basic-auth username:pass1234
179+
# Provide extra flags to the "ngrok http" command, see
180+
# https://ngrok.com/docs#http or run "ngrok http -h"
181+
182+
# disable_settings_management: false
183+
# If true, ddev will not create CMS-specific settings files like
184+
# Drupal's settings.php/settings.ddev.php or TYPO3's AdditionalConfiguration.php
185+
# In this case the user must provide all such settings.
186+
187+
# You can inject environment variables into the web container with:
188+
# web_environment:
189+
# - SOMEENV=somevalue
190+
# - SOMEOTHERENV=someothervalue
191+
192+
# no_project_mount: false
193+
# (Experimental) If true, ddev will not mount the project into the web container;
194+
# the user is responsible for mounting it manually or via a script.
195+
# This is to enable experimentation with alternate file mounting strategies.
196+
# For advanced users only!
197+
198+
# bind_all_interfaces: false
199+
# If true, host ports will be bound on all network interfaces,
200+
# not just the localhost interface. This means that ports
201+
# will be available on the local network if the host firewall
202+
# allows it.
203+
204+
# default_container_timeout: 120
205+
# The default time that ddev waits for all containers to become ready can be increased from
206+
# the default 120. This helps in importing huge databases, for example.
207+
208+
#web_extra_exposed_ports:
209+
#- name: nodejs
210+
# container_port: 3000
211+
# http_port: 2999
212+
# https_port: 3000
213+
#- name: something
214+
# container_port: 4000
215+
# https_port: 4000
216+
# http_port: 3999
217+
# Allows a set of extra ports to be exposed via ddev-router
218+
# The port behavior on the ddev-webserver must be arranged separately, for example
219+
# using web_extra_daemons.
220+
# For example, with a web app on port 3000 inside the container, this config would
221+
# expose that web app on https://<project>.ddev.site:9999 and http://<project>.ddev.site:9998
222+
# web_extra_exposed_ports:
223+
# - container_port: 3000
224+
# http_port: 9998
225+
# https_port: 9999
226+
227+
#web_extra_daemons:
228+
#- name: "http-1"
229+
# command: "/var/www/html/node_modules/.bin/http-server -p 3000"
230+
# directory: /var/www/html
231+
#- name: "http-2"
232+
# command: "/var/www/html/node_modules/.bin/http-server /var/www/html/sub -p 3000"
233+
# directory: /var/www/html
234+
235+
# override_config: false
236+
# By default, config.*.yaml files are *merged* into the configuration
237+
# But this means that some things can't be overridden
238+
# For example, if you have 'nfs_mount_enabled: true'' you can't override it with a merge
239+
# and you can't erase existing hooks or all environment variables.
240+
# However, with "override_config: true" in a particular config.*.yaml file,
241+
# 'nfs_mount_enabled: false' can override the existing values, and
242+
# hooks:
243+
# post_start: []
244+
# or
245+
# web_environment: []
246+
# or
247+
# additional_hostnames: []
248+
# can have their intended affect. 'override_config' affects only behavior of the
249+
# config.*.yaml file it exists in.
250+
251+
# Many ddev commands can be extended to run tasks before or after the
252+
# ddev command is executed, for example "post-start", "post-import-db",
253+
# "pre-composer", "post-composer"
254+
# See https://ddev.readthedocs.io/en/stable/users/extend/custom-commands/ for more
255+
# information on the commands that can be extended and the tasks you can define
256+
# for them. Example:
257+
#hooks:
258+
# Un-comment to emit the WP CLI version after ddev start.
259+
# post-start:
260+
# - exec: wp cli version

.env.example

Lines changed: 17 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,18 @@
1-
APP_HOST=
2-
APP_ENV=local|preprod|production
3-
APP_DOCROOT=web/
4-
APP_CORE=
5-
APP_DEBUG=true|false
6-
APP_SSL=true|false
1+
APP_HOST=wordpress-project.ddev.site
2+
APP_ENV=local # local | preprod | production
3+
APP_DEBUG=true # true | false
4+
APP_SSL=true # true | false
75

8-
# For local development, in order for browserSync to
9-
# work correctly with SSL, it needs to know where the
10-
# SSL certifcate files are stored.
11-
# You can generate local and valid SSL certifcate with
12-
# [mkcert](https://github.com/FiloSottile/mkcert) and
13-
# the following shell command:
14-
#
15-
# ```bash
16-
# mkcert local.studiometa.fr studiometa.fr localhost 127.0.0.1
17-
# ```
18-
APP_SSL_CERT='/path/to/cert'
19-
APP_SSL_KEY='/path/to/key'
20-
21-
DB_HOST=localhost
22-
DB_DATABASE=database_name
23-
DB_USERNAME=root
24-
DB_PASSWORD=root
6+
DB_HOST=db
7+
DB_DATABASE=db
8+
DB_USERNAME=db
9+
DB_PASSWORD=db
2510
DB_PREFIX=wp_
2611

12+
DISABLE_PLUGINS_LOCAL=test/test.php
13+
DISABLE_PLUGINS_PREPROD=test/test.php
14+
DISABLE_PLUGINS_PRODUCTION=test/test.php
15+
2716
AUTH_KEY=''
2817
SECURE_AUTH_KEY=''
2918
LOGGED_IN_KEY=''
@@ -32,3 +21,8 @@ AUTH_SALT=''
3221
SECURE_AUTH_SALT=''
3322
LOGGED_IN_SALT=''
3423
NONCE_SALT=''
24+
25+
# WP Rocket config
26+
WP_ROCKET_EMAIL=''
27+
WP_ROCKET_KEY=''
28+
WP_CACHE=false

.eslintrc.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
module.exports = {
2+
extends: '@studiometa/eslint-config',
3+
};

.gitattributes

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
/web/wp-content/themes/studiometa/dist/** -text -diff

0 commit comments

Comments
 (0)