Compare commits

...

No commits in common. "7f41f34be5ab9860909b5ae8c7ce076579d34e9c" and "e05e9553f55bea538f82ed1803aaa6694b3ec07f" have entirely different histories.

3615 changed files with 57926 additions and 350758 deletions

View file

@ -1,13 +0,0 @@
name: ddev-vite-sidecar
repository: s2b/ddev-vite-sidecar
version: 1.1.0
install_date: "2024-10-02T19:02:43+02:00"
project_files:
- commands/web/vite
- apache/vite.conf
- nginx_full/vite.conf
- vite/vite-server-not-running.html
- config.vite.yaml
- web-build/Dockerfile.vite
global_files: []
removal_actions: []

View file

@ -1,10 +0,0 @@
name: phpmyadmin
repository: ddev/ddev-phpmyadmin
version: v0.3.9
install_date: "2024-11-15T17:27:23+01:00"
project_files:
- docker-compose.phpmyadmin.yaml
- docker-compose.phpmyadmin_norouter.yaml
- commands/host/phpmyadmin
global_files: []
removal_actions: []

View file

@ -1,19 +0,0 @@
name: redis
repository: ddev/ddev-redis-7
version: v2.7.1
install_date: "2024-11-14T13:56:41+01:00"
project_files:
- commands/redis/redis
- commands/redis/redis-flush
- redis/redis.conf
- redis/advanced.conf
- redis/append.conf
- redis/general.conf
- redis/io.conf
- redis/memory.conf
- redis/network.conf
- redis/security.conf
- redis/snapshots.conf
- docker-compose.redis.yaml
global_files: []
removal_actions: []

View file

@ -1,30 +0,0 @@
#ddev-generated
<VirtualHost *:80>
ServerName vite.haikuatelier.fr.ddev.site
DocumentRoot /mnt/ddev_config/vite/
ErrorDocument 503 "/vite-server-not-running.html"
# Proxy development server
ProxyPass / http://localhost:5173/
ProxyPassReverse / http://localhost:5173/
# Proxy websockets
RewriteEngine On
RewriteCond %{HTTP:Upgrade} websocket [NC]
RewriteCond %{HTTP:Connection} upgrade [NC]
RewriteRule ^/?(.*) "ws://localhost:5173/$1" [P,L]
# Do not proxy files in /vite to display the static 503 error message
<Location "/vite-server-not-running.html">
ProxyPass !
</Location>
<Directory "/mnt/ddev_config/vite/">
Require all granted
</Directory>
ErrorLog /dev/stdout
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias "/phpstatus" "/var/www/phpstatus.php"
</VirtualHost>

View file

@ -1,19 +0,0 @@
#!/bin/bash
## #ddev-generated: If you want to edit and own this file, remove this line.
## Description: Launch a browser with PhpMyAdmin
## Usage: phpmyadmin
## Example: "ddev phpmyadmin"
DDEV_PHPMYADMIN_PORT=8036
DDEV_PHPMYADMIN_HTTPS_PORT=8037
if [ ${DDEV_PRIMARY_URL%://*} = "http" ] || [ -n "${GITPOD_WORKSPACE_ID:-}" ] || [ "${CODESPACES:-}" = "true" ]; then
# Gitpod: "gp preview" opens a blank page for PhpMyAdmin, use "xdg-open" instead
if [ "${OSTYPE:-}" = "linux-gnu" ] && [ -n "${GITPOD_WORKSPACE_ID:-}" ] && [ -z "${DDEV_DEBUG:-}" ]; then
xdg-open "$(DDEV_DEBUG=true ddev launch :$DDEV_PHPMYADMIN_PORT | grep "FULLURL" | awk '{print $2}')"
else
ddev launch :$DDEV_PHPMYADMIN_PORT
fi
else
ddev launch :$DDEV_PHPMYADMIN_HTTPS_PORT
fi

View file

@ -1,7 +0,0 @@
#!/bin/sh
#ddev-generated
## Description: Run redis-cli inside the redis container
## Usage: redis [flags] [args]
## Example: "redis KEYS *" or "ddev redis-cli INFO" or "ddev redis-cli --version"
redis-cli -p 6379 -h redis -a redis --no-auth-warning "$@"

View file

@ -1,7 +0,0 @@
#!/bin/bash
#ddev-generated
## Description: Run redis-cli inside the redis container
## Usage: redis-cli [flags] [args]
## Example: "ddev redis-cli KEYS *" or "ddev redis-cli INFO" or "ddev redis-cli --version"
redis-cli -p 6379 -h redis $@

View file

@ -1,7 +0,0 @@
#!/bin/sh
#ddev-generated
## Description: Run redis-cli inside the redis container
## Usage: redis-flush
## Example: "redis-flush"
redis-cli -a redis --no-auth-warning FLUSHALL ASYNC

View file

@ -1,49 +0,0 @@
#!/bin/bash
#ddev-generated
## Description: Run vite inside the web container. Servers started by vite (dev, preview) are proxied and made available at https://vite.$PROJECTNAME.ddev.site
## Usage: vite dev|serve|build|optimize|preview [flags] [args]
## Example: "ddev vite" or "ddev vite build" or "ddev vite build --outDir path/to/output/"
## ExecRaw: true
## HostWorkingDir: true
## AutocompleteTerms: ["dev","serve","build","optimize","preview"]
# Preferred package manager can be specified via VITE_PACKAGE_MANAGER environment variable in config.vite.yaml
PACKAGE_MANAGER="${VITE_PACKAGE_MANAGER:-npm}"
COMMAND="${1:-dev}"
OPTIONS=$@
case $PACKAGE_MANAGER in
npm | npx)
PACKAGE_MANAGER_COMMAND="npx vite"
;;
yarn)
PACKAGE_MANAGER_COMMAND="yarn exec vite --"
;;
pnpm)
PACKAGE_MANAGER_COMMAND="pnpm exec vite"
;;
bun)
PACKAGE_MANAGER_COMMAND="bun vite"
;;
*)
echo "Invalid node package manager specified: $PACKAGE_MANAGER"
exit 1
;;
esac
if [[ "${COMMAND:0:1}" == "-" ]]; then
COMMAND="dev"
else
OPTIONS="${@:2}"
fi
echo "Using $PACKAGE_MANAGER to run vite..."
if [[ $COMMAND == "dev" ]] || [[ $COMMAND == "serve" ]] || [[ $COMMAND == "preview" ]]; then
$PACKAGE_MANAGER_COMMAND $COMMAND --host --port 5173 --strictPort $OPTIONS
else
$PACKAGE_MANAGER_COMMAND $COMMAND $OPTIONS
fi

View file

@ -1,16 +0,0 @@
# ddev-generated
additional_hostnames:
- vite.haikuatelier.fr
web_environment:
- VITE_SERVER_URI=https://vite.haikuatelier.fr.ddev.site
- VITE_PACKAGE_MANAGER=pnpm
# Enable these lines if you want to expose the vite port to the host system
# Note that this means that only one ddev project with vite can be run at a time
# as the different processes might interfere with each other
#
# web_extra_exposed_ports:
# - name: vite
# container_port: 5173
# http_port: 5172
# https_port: 5173

View file

@ -1,286 +0,0 @@
name: haikuatelier.fr
type: wordpress
docroot: web
php_version: "8.4"
webserver_type: nginx-fpm
xdebug_enabled: false
additional_hostnames:
- vite.haikuatelier.fr
additional_fqdns: []
database:
type: mariadb
version: "11.4"
use_dns_when_possible: true
composer_version: "2"
web_environment:
- VITE_SERVER_URI=https://vite.haikuatelier.fr.ddev.site
- VITE_PACKAGE_MANAGER=pnpm
corepack_enable: true
# Key features of DDEV's config.yaml:
# name: <projectname> # Name of the project, automatically provides
# http://projectname.ddev.site and https://projectname.ddev.site
# type: <projecttype> # backdrop, cakephp, craftcms, drupal, drupal6, drupal7, drupal8, drupal9, drupal10, drupal11, laravel, magento, magento2, php, shopware6, silverstripe, symfony, typo3, wordpress
# See https://ddev.readthedocs.io/en/stable/users/quickstart/ for more
# information on the different project types
# docroot: <relative_path> # Relative path to the directory containing index.php.
# php_version: "8.3" # PHP version to use, "5.6" through "8.4"
# You can explicitly specify the webimage but this
# is not recommended, as the images are often closely tied to DDEV's' behavior,
# so this can break upgrades.
# webimage: <docker_image> # nginx/php docker image.
# database:
# type: <dbtype> # mysql, mariadb, postgres
# version: <version> # database version, like "10.11" or "8.0"
# MariaDB versions can be 5.5-10.8, 10.11, and 11.4.
# MySQL versions can be 5.5-8.0.
# PostgreSQL versions can be 9-17.
# router_http_port: <port> # Port to be used for http (defaults to global configuration, usually 80)
# router_https_port: <port> # Port for https (defaults to global configuration, usually 443)
# xdebug_enabled: false # Set to true to enable Xdebug and "ddev start" or "ddev restart"
# Note that for most people the commands
# "ddev xdebug" to enable Xdebug and "ddev xdebug off" to disable it work better,
# as leaving Xdebug enabled all the time is a big performance hit.
# xhprof_enabled: false # Set to true to enable Xhprof and "ddev start" or "ddev restart"
# Note that for most people the commands
# "ddev xhprof" to enable Xhprof and "ddev xhprof off" to disable it work better,
# as leaving Xhprof enabled all the time is a big performance hit.
# webserver_type: nginx-fpm or apache-fpm
# timezone: Europe/Berlin
# If timezone is unset, DDEV will attempt to derive it from the host system timezone
# using the $TZ environment variable or the /etc/localtime symlink.
# This is the timezone used in the containers and by PHP;
# it can be set to any valid timezone,
# see https://en.wikipedia.org/wiki/List_of_tz_database_time_zones
# For example Europe/Dublin or MST7MDT
# composer_root: <relative_path>
# Relative path to the Composer root directory from the project root. This is
# the directory which contains the composer.json and where all Composer related
# commands are executed.
# composer_version: "2"
# You can set it to "" or "2" (default) for Composer v2 or "1" for Composer v1
# to use the latest major version available at the time your container is built.
# It is also possible to use each other Composer version channel. This includes:
# - 2.2 (latest Composer LTS version)
# - stable
# - preview
# - snapshot
# Alternatively, an explicit Composer version may be specified, for example "2.2.18".
# To reinstall Composer after the image was built, run "ddev debug rebuild".
# nodejs_version: "22"
# change from the default system Node.js version to any other version.
# See https://ddev.readthedocs.io/en/stable/users/configuration/config/#nodejs_version for more information
# and https://www.npmjs.com/package/n#specifying-nodejs-versions for the full documentation,
# Note that using of 'ddev nvm' is discouraged because "nodejs_version" is much easier to use,
# can specify any version, and is more robust than using 'nvm'.
# corepack_enable: false
# Change to 'true' to 'corepack enable' and gain access to latest versions of yarn/pnpm
# additional_hostnames:
# - somename
# - someothername
# would provide http and https URLs for "somename.ddev.site"
# and "someothername.ddev.site".
# additional_fqdns:
# - example.com
# - sub1.example.com
# would provide http and https URLs for "example.com" and "sub1.example.com"
# Please take care with this because it can cause great confusion.
# upload_dirs: "custom/upload/dir"
#
# upload_dirs:
# - custom/upload/dir
# - ../private
#
# would set the destination paths for ddev import-files to <docroot>/custom/upload/dir
# When Mutagen is enabled this path is bind-mounted so that all the files
# in the upload_dirs don't have to be synced into Mutagen.
# disable_upload_dirs_warning: false
# If true, turns off the normal warning that says
# "You have Mutagen enabled and your 'php' project type doesn't have upload_dirs set"
# ddev_version_constraint: ""
# Example:
# ddev_version_constraint: ">= 1.22.4"
# This will enforce that the running ddev version is within this constraint.
# See https://github.com/Masterminds/semver#checking-version-constraints for
# supported constraint formats
# working_dir:
# web: /var/www/html
# db: /home
# would set the default working directory for the web and db services.
# These values specify the destination directory for ddev ssh and the
# directory in which commands passed into ddev exec are run.
# omit_containers: [db, ddev-ssh-agent]
# Currently only these containers are supported. Some containers can also be
# omitted globally in the ~/.ddev/global_config.yaml. Note that if you omit
# the "db" container, several standard features of DDEV that access the
# database container will be unusable. In the global configuration it is also
# possible to omit ddev-router, but not here.
# performance_mode: "global"
# DDEV offers performance optimization strategies to improve the filesystem
# performance depending on your host system. Should be configured globally.
#
# If set, will override the global config. Possible values are:
# - "global": uses the value from the global config.
# - "none": disables performance optimization for this project.
# - "mutagen": enables Mutagen for this project.
# - "nfs": enables NFS for this project.
#
# See https://ddev.readthedocs.io/en/stable/users/install/performance/#nfs
# See https://ddev.readthedocs.io/en/stable/users/install/performance/#mutagen
# fail_on_hook_fail: False
# Decide whether 'ddev start' should be interrupted by a failing hook
# host_https_port: "59002"
# The host port binding for https can be explicitly specified. It is
# dynamic unless otherwise specified.
# This is not used by most people, most people use the *router* instead
# of the localhost port.
# host_webserver_port: "59001"
# The host port binding for the ddev-webserver can be explicitly specified. It is
# dynamic unless otherwise specified.
# This is not used by most people, most people use the *router* instead
# of the localhost port.
# host_db_port: "59002"
# The host port binding for the ddev-dbserver can be explicitly specified. It is dynamic
# unless explicitly specified.
# mailpit_http_port: "8025"
# mailpit_https_port: "8026"
# The Mailpit ports can be changed from the default 8025 and 8026
# host_mailpit_port: "8025"
# The mailpit port is not normally bound on the host at all, instead being routed
# through ddev-router, but it can be bound directly to localhost if specified here.
# webimage_extra_packages: [php7.4-tidy, php-bcmath]
# Extra Debian packages that are needed in the webimage can be added here
# dbimage_extra_packages: [telnet,netcat]
# Extra Debian packages that are needed in the dbimage can be added here
# use_dns_when_possible: true
# If the host has internet access and the domain configured can
# successfully be looked up, DNS will be used for hostname resolution
# instead of editing /etc/hosts
# Defaults to true
# project_tld: ddev.site
# The top-level domain used for project URLs
# The default "ddev.site" allows DNS lookup via a wildcard
# If you prefer you can change this to "ddev.local" to preserve
# pre-v1.9 behavior.
# ngrok_args: --basic-auth username:pass1234
# Provide extra flags to the "ngrok http" command, see
# https://ngrok.com/docs/ngrok-agent/config or run "ngrok http -h"
# disable_settings_management: false
# If true, DDEV will not create CMS-specific settings files like
# Drupal's settings.php/settings.ddev.php or TYPO3's additional.php
# In this case the user must provide all such settings.
# You can inject environment variables into the web container with:
# web_environment:
# - SOMEENV=somevalue
# - SOMEOTHERENV=someothervalue
# no_project_mount: false
# (Experimental) If true, DDEV will not mount the project into the web container;
# the user is responsible for mounting it manually or via a script.
# This is to enable experimentation with alternate file mounting strategies.
# For advanced users only!
# bind_all_interfaces: false
# If true, host ports will be bound on all network interfaces,
# not the localhost interface only. This means that ports
# will be available on the local network if the host firewall
# allows it.
# default_container_timeout: 120
# The default time that DDEV waits for all containers to become ready can be increased from
# the default 120. This helps in importing huge databases, for example.
# web_extra_exposed_ports:
# - name: nodejs
# container_port: 3000
# http_port: 2999
# https_port: 3000
# - name: something
# container_port: 4000
# https_port: 4000
# http_port: 3999
# Allows a set of extra ports to be exposed via ddev-router
# Fill in all three fields even if you dont intend to use the https_port!
# If you dont add https_port, then it defaults to 0 and ddev-router will fail to start.
#
# The port behavior on the ddev-webserver must be arranged separately, for example
# using web_extra_daemons.
# For example, with a web app on port 3000 inside the container, this config would
# expose that web app on https://<project>.ddev.site:9999 and http://<project>.ddev.site:9998
# web_extra_exposed_ports:
# - name: myapp
# container_port: 3000
# http_port: 9998
# https_port: 9999
# web_extra_daemons:
# - name: "http-1"
# command: "/var/www/html/node_modules/.bin/http-server -p 3000"
# directory: /var/www/html
# - name: "http-2"
# command: "/var/www/html/node_modules/.bin/http-server /var/www/html/sub -p 3000"
# directory: /var/www/html
# override_config: false
# By default, config.*.yaml files are *merged* into the configuration
# But this means that some things can't be overridden
# For example, if you have 'use_dns_when_possible: true'' you can't override it with a merge
# and you can't erase existing hooks or all environment variables.
# However, with "override_config: true" in a particular config.*.yaml file,
# 'use_dns_when_possible: false' can override the existing values, and
# hooks:
# post-start: []
# or
# web_environment: []
# or
# additional_hostnames: []
# can have their intended affect. 'override_config' affects only behavior of the
# config.*.yaml file it exists in.
# Many DDEV commands can be extended to run tasks before or after the
# DDEV command is executed, for example "post-start", "post-import-db",
# "pre-composer", "post-composer"
# See https://ddev.readthedocs.io/en/stable/users/extend/custom-commands/ for more
# information on the commands that can be extended and the tasks you can define
# for them. Example:
# hooks:
# Un-comment to emit the WP CLI version after ddev start.
# post-start:
# - exec: wp cli version

View file

@ -1,30 +0,0 @@
# ddev-generated
services:
phpmyadmin:
container_name: ddev-${DDEV_SITENAME}-phpmyadmin
image: phpmyadmin:5.2.0
working_dir: "/root"
restart: "no"
labels:
com.ddev.site-name: ${DDEV_SITENAME}
com.ddev.approot: $DDEV_APPROOT
volumes:
- ".:/mnt/ddev_config"
- "ddev-global-cache:/mnt/ddev-global-cache"
expose:
- "80"
environment:
- PMA_USER=root
- PMA_PASSWORD=root
- PMA_HOST=db
- PMA_PORT=3306
- VIRTUAL_HOST=$DDEV_HOSTNAME
- UPLOAD_LIMIT=4000M
- HTTP_EXPOSE=8036:80
- HTTPS_EXPOSE=8037:80
healthcheck:
interval: 120s
timeout: 2s
retries: 1
depends_on:
- db

View file

@ -1,4 +0,0 @@
# ddev-generated
# If omit_containers[ddev-router] then this file will be replaced
# with another with a `ports` statement to directly expose port 80 to 8036
services: {}

View file

@ -1,34 +0,0 @@
# ddev-generated
volumes:
redis:
name: ddev-${DDEV_SITENAME}-redis
labels:
com.ddev.site-name: ${DDEV_SITENAME}
services:
redis:
container_name: ddev-${DDEV_SITENAME}-redis
hostname: ddev-${DDEV_SITENAME}-minio
image: redis:7.2-alpine
command: /etc/redis/conf/redis.conf
volumes:
- ".:/mnt/ddev_config"
- "ddev-global-cache:/mnt/ddev-global-cache"
- "./redis:/etc/redis/conf"
- "redis:/data"
expose:
- 6379
networks:
- default
deploy:
resources:
limits:
cpus: "2.5"
memory: "768M"
reservations:
cpus: "1.5"
memory: "512M"
restart: "no"
labels:
com.ddev.site-name: ${DDEV_SITENAME}
com.ddev.approot: $DDEV_APPROOT

View file

@ -1,33 +0,0 @@
#ddev-generated
server {
server_name vite.haikuatelier.fr.ddev.site;
listen 80;
listen 443 ssl;
ssl_certificate /etc/ssl/certs/master.crt;
ssl_certificate_key /etc/ssl/certs/master.key;
include /etc/nginx/monitoring.conf;
# Disable sendfile as per https://docs.vagrantup.com/v2/synced-folders/virtualbox.html
sendfile off;
error_log /dev/stdout info;
access_log off;
location /vite-server-not-running.html {
root /mnt/ddev_config/vite/;
}
location / {
proxy_pass http://localhost:5173;
proxy_http_version 1.1;
proxy_set_header Upgrade $http_upgrade;
proxy_set_header Connection "Upgrade";
proxy_set_header Host $host;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_set_header X-Forwarded-Proto $http_x_forwarded_proto;
proxy_set_header X-Forwarded-Host $http_x_forwarded_host;
error_page 502 /vite-server-not-running.html;
}
}

View file

@ -1,341 +0,0 @@
# #ddev-generated
############################### ADVANCED CONFIG ###############################
# Hashes are encoded using a memory efficient data structure when they have a
# small number of entries, and the biggest entry does not exceed a given
# threshold. These thresholds can be configured using the following directives.
hash-max-ziplist-entries 512
hash-max-ziplist-value 64
# Lists are also encoded in a special way to save a lot of space.
# The number of entries allowed per internal list node can be specified
# as a fixed maximum size or a maximum number of elements.
# For a fixed maximum size, use -5 through -1, meaning:
# -5: max size: 64 Kb <-- not recommended for normal workloads
# -4: max size: 32 Kb <-- not recommended
# -3: max size: 16 Kb <-- probably not recommended
# -2: max size: 8 Kb <-- good
# -1: max size: 4 Kb <-- good
# Positive numbers mean store up to _exactly_ that number of elements
# per list node.
# The highest performing option is usually -2 (8 Kb size) or -1 (4 Kb size),
# but if your use case is unique, adjust the settings as necessary.
list-max-ziplist-size -2
# Lists may also be compressed.
# Compress depth is the number of quicklist ziplist nodes from *each* side of
# the list to *exclude* from compression. The head and tail of the list
# are always uncompressed for fast push/pop operations. Settings are:
# 0: disable all list compression
# 1: depth 1 means "don't start compressing until after 1 node into the list,
# going from either the head or tail"
# So: [head]->node->node->...->node->[tail]
# [head], [tail] will always be uncompressed; inner nodes will compress.
# 2: [head]->[next]->node->node->...->node->[prev]->[tail]
# 2 here means: don't compress head or head->next or tail->prev or tail,
# but compress all nodes between them.
# 3: [head]->[next]->[next]->node->node->...->node->[prev]->[prev]->[tail]
# etc.
list-compress-depth 0
# Sets have a special encoding in just one case: when a set is composed
# of just strings that happen to be integers in radix 10 in the range
# of 64 bit signed integers.
# The following configuration setting sets the limit in the size of the
# set in order to use this special memory saving encoding.
set-max-intset-entries 512
# Similarly to hashes and lists, sorted sets are also specially encoded in
# order to save a lot of space. This encoding is only used when the length and
# elements of a sorted set are below the following limits:
zset-max-ziplist-entries 128
zset-max-ziplist-value 64
# HyperLogLog sparse representation bytes limit. The limit includes the
# 16 bytes header. When an HyperLogLog using the sparse representation crosses
# this limit, it is converted into the dense representation.
#
# A value greater than 16000 is totally useless, since at that point the
# dense representation is more memory efficient.
#
# The suggested value is ~ 3000 in order to have the benefits of
# the space efficient encoding without slowing down too much PFADD,
# which is O(N) with the sparse encoding. The value can be raised to
# ~ 10000 when CPU is not a concern, but space is, and the data set is
# composed of many HyperLogLogs with cardinality in the 0 - 15000 range.
hll-sparse-max-bytes 3000
# Streams macro node max size / items. The stream data structure is a radix
# tree of big nodes that encode multiple items inside. Using this configuration
# it is possible to configure how big a single node can be in bytes, and the
# maximum number of items it may contain before switching to a new node when
# appending new stream entries. If any of the following settings are set to
# zero, the limit is ignored, so for instance it is possible to set just a
# max entires limit by setting max-bytes to 0 and max-entries to the desired
# value.
stream-node-max-bytes 4096
stream-node-max-entries 100
# Active rehashing uses 1 millisecond every 100 milliseconds of CPU time in
# order to help rehashing the main Redis hash table (the one mapping top-level
# keys to values). The hash table implementation Redis uses (see dict.c)
# performs a lazy rehashing: the more operation you run into a hash table
# that is rehashing, the more rehashing "steps" are performed, so if the
# server is idle the rehashing is never complete and some more memory is used
# by the hash table.
#
# The default is to use this millisecond 10 times every second in order to
# actively rehash the main dictionaries, freeing memory when possible.
#
# If unsure:
# use "activerehashing no" if you have hard latency requirements and it is
# not a good thing in your environment that Redis can reply from time to time
# to queries with 2 milliseconds delay.
#
# use "activerehashing yes" if you don't have such hard requirements but
# want to free memory asap when possible.
activerehashing yes
# The client output buffer limits can be used to force disconnection of clients
# that are not reading data from the server fast enough for some reason (a
# common reason is that a Pub/Sub client can't consume messages as fast as the
# publisher can produce them).
#
# The limit can be set differently for the three different classes of clients:
#
# normal -> normal clients including MONITOR clients
# replica -> replica clients
# pubsub -> clients subscribed to at least one pubsub channel or pattern
#
# The syntax of every client-output-buffer-limit directive is the following:
#
# client-output-buffer-limit <class> <hard limit> <soft limit> <soft seconds>
#
# A client is immediately disconnected once the hard limit is reached, or if
# the soft limit is reached and remains reached for the specified number of
# seconds (continuously).
# So for instance if the hard limit is 32 megabytes and the soft limit is
# 16 megabytes / 10 seconds, the client will get disconnected immediately
# if the size of the output buffers reach 32 megabytes, but will also get
# disconnected if the client reaches 16 megabytes and continuously overcomes
# the limit for 10 seconds.
#
# By default normal clients are not limited because they don't receive data
# without asking (in a push way), but just after a request, so only
# asynchronous clients may create a scenario where data is requested faster
# than it can read.
#
# Instead there is a default limit for pubsub and replica clients, since
# subscribers and replicas receive data in a push fashion.
#
# Both the hard or the soft limit can be disabled by setting them to zero.
client-output-buffer-limit normal 0 0 0
client-output-buffer-limit replica 256mb 64mb 60
client-output-buffer-limit pubsub 32mb 8mb 60
# Client query buffers accumulate new commands. They are limited to a fixed
# amount by default in order to avoid that a protocol desynchronization (for
# instance due to a bug in the client) will lead to unbound memory usage in
# the query buffer. However you can configure it here if you have very special
# needs, such us huge multi/exec requests or alike.
#
# client-query-buffer-limit 1gb
# In the Redis protocol, bulk requests, that are, elements representing single
# strings, are normally limited to 512 mb. However you can change this limit
# here, but must be 1mb or greater
#
# proto-max-bulk-len 512mb
# Redis calls an internal function to perform many background tasks, like
# closing connections of clients in timeout, purging expired keys that are
# never requested, and so forth.
#
# Not all tasks are performed with the same frequency, but Redis checks for
# tasks to perform according to the specified "hz" value.
#
# By default "hz" is set to 10. Raising the value will use more CPU when
# Redis is idle, but at the same time will make Redis more responsive when
# there are many keys expiring at the same time, and timeouts may be
# handled with more precision.
#
# The range is between 1 and 500, however a value over 100 is usually not
# a good idea. Most users should use the default of 10 and raise this up to
# 100 only in environments where very low latency is required.
hz 10
# Normally it is useful to have an HZ value which is proportional to the
# number of clients connected. This is useful in order, for instance, to
# avoid too many clients are processed for each background task invocation
# in order to avoid latency spikes.
#
# Since the default HZ value by default is conservatively set to 10, Redis
# offers, and enables by default, the ability to use an adaptive HZ value
# which will temporarily raise when there are many connected clients.
#
# When dynamic HZ is enabled, the actual configured HZ will be used
# as a baseline, but multiples of the configured HZ value will be actually
# used as needed once more clients are connected. In this way an idle
# instance will use very little CPU time while a busy instance will be
# more responsive.
dynamic-hz yes
# When a child rewrites the AOF file, if the following option is enabled
# the file will be fsync-ed every 32 MB of data generated. This is useful
# in order to commit the file to the disk more incrementally and avoid
# big latency spikes.
aof-rewrite-incremental-fsync yes
# When redis saves RDB file, if the following option is enabled
# the file will be fsync-ed every 32 MB of data generated. This is useful
# in order to commit the file to the disk more incrementally and avoid
# big latency spikes.
rdb-save-incremental-fsync yes
# Redis LFU eviction (see maxmemory setting) can be tuned. However it is a good
# idea to start with the default settings and only change them after investigating
# how to improve the performances and how the keys LFU change over time, which
# is possible to inspect via the OBJECT FREQ command.
#
# There are two tunable parameters in the Redis LFU implementation: the
# counter logarithm factor and the counter decay time. It is important to
# understand what the two parameters mean before changing them.
#
# The LFU counter is just 8 bits per key, it's maximum value is 255, so Redis
# uses a probabilistic increment with logarithmic behavior. Given the value
# of the old counter, when a key is accessed, the counter is incremented in
# this way:
#
# 1. A random number R between 0 and 1 is extracted.
# 2. A probability P is calculated as 1/(old_value*lfu_log_factor+1).
# 3. The counter is incremented only if R < P.
#
# The default lfu-log-factor is 10. This is a table of how the frequency
# counter changes with a different number of accesses with different
# logarithmic factors:
#
# +--------+------------+------------+------------+------------+------------+
# | factor | 100 hits | 1000 hits | 100K hits | 1M hits | 10M hits |
# +--------+------------+------------+------------+------------+------------+
# | 0 | 104 | 255 | 255 | 255 | 255 |
# +--------+------------+------------+------------+------------+------------+
# | 1 | 18 | 49 | 255 | 255 | 255 |
# +--------+------------+------------+------------+------------+------------+
# | 10 | 10 | 18 | 142 | 255 | 255 |
# +--------+------------+------------+------------+------------+------------+
# | 100 | 8 | 11 | 49 | 143 | 255 |
# +--------+------------+------------+------------+------------+------------+
#
# NOTE: The above table was obtained by running the following commands:
#
# redis-benchmark -n 1000000 incr foo
# redis-cli object freq foo
#
# NOTE 2: The counter initial value is 5 in order to give new objects a chance
# to accumulate hits.
#
# The counter decay time is the time, in minutes, that must elapse in order
# for the key counter to be divided by two (or decremented if it has a value
# less <= 10).
#
# The default value for the lfu-decay-time is 1. A special value of 0 means to
# decay the counter every time it happens to be scanned.
#
# lfu-log-factor 10
# lfu-decay-time 1
############################## DEBUG COMMAND #############################
enable-debug-command yes
########################### ACTIVE DEFRAGMENTATION #######################
#
# What is active defragmentation?
# -------------------------------
#
# Active (online) defragmentation allows a Redis server to compact the
# spaces left between small allocations and deallocations of data in memory,
# thus allowing to reclaim back memory.
#
# Fragmentation is a natural process that happens with every allocator (but
# less so with Jemalloc, fortunately) and certain workloads. Normally a server
# restart is needed in order to lower the fragmentation, or at least to flush
# away all the data and create it again. However thanks to this feature
# implemented by Oran Agra for Redis 4.0 this process can happen at runtime
# in a "hot" way, while the server is running.
#
# Basically when the fragmentation is over a certain level (see the
# configuration options below) Redis will start to create new copies of the
# values in contiguous memory regions by exploiting certain specific Jemalloc
# features (in order to understand if an allocation is causing fragmentation
# and to allocate it in a better place), and at the same time, will release the
# old copies of the data. This process, repeated incrementally for all the keys
# will cause the fragmentation to drop back to normal values.
#
# Important things to understand:
#
# 1. This feature is disabled by default, and only works if you compiled Redis
# to use the copy of Jemalloc we ship with the source code of Redis.
# This is the default with Linux builds.
#
# 2. You never need to enable this feature if you don't have fragmentation
# issues.
#
# 3. Once you experience fragmentation, you can enable this feature when
# needed with the command "CONFIG SET activedefrag yes".
#
# The configuration parameters are able to fine tune the behavior of the
# defragmentation process. If you are not sure about what they mean it is
# a good idea to leave the defaults untouched.
# Enabled active defragmentation
# activedefrag no
# Minimum amount of fragmentation waste to start active defrag
# active-defrag-ignore-bytes 100mb
# Minimum percentage of fragmentation to start active defrag
# active-defrag-threshold-lower 10
# Maximum percentage of fragmentation at which we use maximum effort
# active-defrag-threshold-upper 100
# Minimal effort for defrag in CPU percentage, to be used when the lower
# threshold is reached
# active-defrag-cycle-min 1
# Maximal effort for defrag in CPU percentage, to be used when the upper
# threshold is reached
# active-defrag-cycle-max 25
# Maximum number of set/hash/zset/list fields that will be processed from
# the main dictionary scan
# active-defrag-max-scan-fields 1000
# Jemalloc background thread for purging will be enabled by default
jemalloc-bg-thread yes
# It is possible to pin different threads and processes of Redis to specific
# CPUs in your system, in order to maximize the performances of the server.
# This is useful both in order to pin different Redis threads in different
# CPUs, but also in order to make sure that multiple Redis instances running
# in the same host will be pinned to different CPUs.
#
# Normally you can do this using the "taskset" command, however it is also
# possible to this via Redis configuration directly, both in Linux and FreeBSD.
#
# You can pin the server/IO threads, bio threads, aof rewrite child process, and
# the bgsave child process. The syntax to specify the cpu list is the same as
# the taskset command:
#
# Set redis server/io threads to cpu affinity 0,2,4,6:
# server_cpulist 0-7:2
#
# Set bio threads to cpu affinity 1,3:
# bio_cpulist 1,3
#
# Set aof rewrite child process to cpu affinity 8,9,10,11:
# aof_rewrite_cpulist 8-11
#
# Set bgsave child process to cpu affinity 1,10,11
# bgsave_cpulist 1,10-11

View file

@ -1,133 +0,0 @@
# #ddev-generated
############################## APPEND ONLY MODE ###############################
# By default Redis asynchronously dumps the dataset on disk. This mode is
# good enough in many applications, but an issue with the Redis process or
# a power outage may result into a few minutes of writes lost (depending on
# the configured save points).
#
# The Append Only File is an alternative persistence mode that provides
# much better durability. For instance using the default data fsync policy
# (see later in the config file) Redis can lose just one second of writes in a
# dramatic event like a server power outage, or a single write if something
# wrong with the Redis process itself happens, but the operating system is
# still running correctly.
#
# AOF and RDB persistence can be enabled at the same time without problems.
# If the AOF is enabled on startup Redis will load the AOF, that is the file
# with the better durability guarantees.
#
# Please check http://redis.io/topics/persistence for more information.
appendonly yes
# The name of the append only file (default: "appendonly.aof")
appendfilename "appendonly.aof"
# For convenience, Redis stores all persistent append-only files in a dedicated
# directory. The name of the directory is determined by the appenddirname
# configuration parameter.
appenddirname "append"
# The fsync() call tells the Operating System to actually write data on disk
# instead of waiting for more data in the output buffer. Some OS will really flush
# data on disk, some other OS will just try to do it ASAP.
#
# Redis supports three different modes:
#
# no: don't fsync, just let the OS flush the data when it wants. Faster.
# always: fsync after every write to the append only log. Slow, Safest.
# everysec: fsync only one time every second. Compromise.
#
# The default is "everysec", as that's usually the right compromise between
# speed and data safety. It's up to you to understand if you can relax this to
# "no" that will let the operating system flush the output buffer when
# it wants, for better performances (but if you can live with the idea of
# some data loss consider the default persistence mode that's snapshotting),
# or on the contrary, use "always" that's very slow but a bit safer than
# everysec.
#
# More details please check the following article:
# http://antirez.com/post/redis-persistence-demystified.html
#
# If unsure, use "everysec".
appendfsync no
# When the AOF fsync policy is set to always or everysec, and a background
# saving process (a background save or AOF log background rewriting) is
# performing a lot of I/O against the disk, in some Linux configurations
# Redis may block too long on the fsync() call. Note that there is no fix for
# this currently, as even performing fsync in a different thread will block
# our synchronous write(2) call.
#
# In order to mitigate this problem it's possible to use the following option
# that will prevent fsync() from being called in the main process while a
# BGSAVE or BGREWRITEAOF is in progress.
#
# This means that while another child is saving, the durability of Redis is
# the same as "appendfsync none". In practical terms, this means that it is
# possible to lose up to 30 seconds of log in the worst scenario (with the
# default Linux settings).
#
# If you have latency problems turn this to "yes". Otherwise leave it as
# "no" that is the safest pick from the point of view of durability.
no-appendfsync-on-rewrite no
# Automatic rewrite of the append only file.
# Redis is able to automatically rewrite the log file implicitly calling
# BGREWRITEAOF when the AOF log size grows by the specified percentage.
#
# This is how it works: Redis remembers the size of the AOF file after the
# latest rewrite (if no rewrite has happened since the restart, the size of
# the AOF at startup is used).
#
# This base size is compared to the current size. If the current size is
# bigger than the specified percentage, the rewrite is triggered. Also
# you need to specify a minimal size for the AOF file to be rewritten, this
# is useful to avoid rewriting the AOF file even if the percentage increase
# is reached but it is still pretty small.
#
# Specify a percentage of zero in order to disable the automatic AOF
# rewrite feature.
auto-aof-rewrite-percentage 100
auto-aof-rewrite-min-size 64mb
# An AOF file may be found to be truncated at the end during the Redis
# startup process, when the AOF data gets loaded back into memory.
# This may happen when the system where Redis is running
# crashes, especially when an ext4 filesystem is mounted without the
# data=ordered option (however this can't happen when Redis itself
# crashes or aborts but the operating system still works correctly).
#
# Redis can either exit with an error when this happens, or load as much
# data as possible (the default now) and start if the AOF file is found
# to be truncated at the end. The following option controls this behavior.
#
# If aof-load-truncated is set to yes, a truncated AOF file is loaded and
# the Redis server starts emitting a log to inform the user of the event.
# Otherwise if the option is set to no, the server aborts with an error
# and refuses to start. When the option is set to no, the user requires
# to fix the AOF file using the "redis-check-aof" utility before to restart
# the server.
#
# Note that if the AOF file will be found to be corrupted in the middle
# the server will still exit with an error. This option only applies when
# Redis will try to read more data from the AOF file but not enough bytes
# will be found.
aof-load-truncated yes
# When rewriting the AOF file, Redis is able to use an RDB preamble in the
# AOF file for faster rewrites and recoveries. When this option is turned
# on the rewritten AOF file is composed of two different stanzas:
#
# [RDB file][AOF tail]
#
# When loading, Redis recognizes that the AOF file starts with the "REDIS"
# string and loads the prefixed RDB file, then continues loading the AOF
# tail.
aof-use-rdb-preamble yes

View file

@ -1,44 +0,0 @@
# #ddev-generated
################################# GENERAL #####################################
# By default Redis does not run as a daemon. Use 'yes' if you need it.
# Note that Redis will write a pid file in /var/run/redis.pid when daemonized.
daemonize no
# If you run Redis from upstart or systemd, Redis can interact with your
# supervision tree. Options:
# supervised no - no supervision interaction
# supervised upstart - signal upstart by putting Redis into SIGSTOP mode
# requires "expect stop" in your upstart job config
# supervised systemd - signal systemd by writing READY=1 to $NOTIFY_SOCKET
# supervised auto - detect upstart or systemd method based on
# UPSTART_JOB or NOTIFY_SOCKET environment variables
# Note: these supervision methods only signal "process is ready."
# They do not enable continuous pings back to your supervisor.
supervised no
# Specify the server verbosity level.
# This can be one of:
# debug (a lot of information, useful for development/testing)
# verbose (many rarely useful info, but not a mess like the debug level)
# notice (moderately verbose, what you want in production probably)
# warning (only very important / critical messages are logged)
loglevel notice
# Specify the log file name. Also the empty string can be used to force
# Redis to log on the standard output. Note that if you use standard
# output for logging but daemonize, logs will be sent to /dev/null
logfile ""
# Set the number of databases. The default database is DB 0, you can select
# a different one on a per-connection basis using SELECT <dbid> where
# dbid is a number between 0 and 'databases'-1
databases 4
# By default Redis shows an ASCII art logo only when started to log to the
# standard output and if the standard output is a TTY. Basically this means
# that normally a logo is displayed only in interactive sessions.
#
# However it is possible to force the pre-4.0 behavior and always show a
# ASCII art logo in startup logs by setting the following option to yes.
always-show-logo yes

View file

@ -1,98 +0,0 @@
# #ddev-generated
################################ THREADED I/O #################################
# Redis is mostly single threaded, however there are certain threaded
# operations such as UNLINK, slow I/O accesses and other things that are
# performed on side threads.
#
# Now it is also possible to handle Redis clients socket reads and writes
# in different I/O threads. Since especially writing is so slow, normally
# Redis users use pipelining in order to speed up the Redis performances per
# core, and spawn multiple instances in order to scale more. Using I/O
# threads it is possible to easily speedup two times Redis without resorting
# to pipelining nor sharding of the instance.
#
# By default threading is disabled, we suggest enabling it only in machines
# that have at least 4 or more cores, leaving at least one spare core.
# Using more than 8 threads is unlikely to help much. We also recommend using
# threaded I/O only if you actually have performance problems, with Redis
# instances being able to use a quite big percentage of CPU time, otherwise
# there is no point in using this feature.
#
# So for instance if you have a four cores boxes, try to use 2 or 3 I/O
# threads, if you have a 8 cores, try to use 6 threads. In order to
# enable I/O threads use the following configuration directive:
#
io-threads 1
#
# Setting io-threads to 1 will just use the main thread as usual.
# When I/O threads are enabled, we only use threads for writes, that is
# to thread the write(2) syscall and transfer the client buffers to the
# socket. However it is also possible to enable threading of reads and
# protocol parsing using the following configuration directive, by setting
# it to yes:
#
io-threads-do-reads no
#
# Usually threading reads doesn't help much.
#
# NOTE 1: This configuration directive cannot be changed at runtime via
# CONFIG SET. Aso this feature currently does not work when SSL is
# enabled.
#
# NOTE 2: If you want to test the Redis speedup using redis-benchmark, make
# sure you also run the benchmark itself in threaded mode, using the
# --threads option to match the number of Redis threads, otherwise you'll not
# be able to notice the improvements.
############################ KERNEL OOM CONTROL ##############################
# On Linux, it is possible to hint the kernel OOM killer on what processes
# should be killed first when out of memory.
#
# Enabling this feature makes Redis actively control the oom_score_adj value
# for all its processes, depending on their role. The default scores will
# attempt to have background child processes killed before all others, and
# replicas killed before masters.
oom-score-adj no
# When oom-score-adj is used, this directive controls the specific values used
# for master, replica and background child processes. Values range -1000 to
# 1000 (higher means more likely to be killed).
#
# Unprivileged processes (not root, and without CAP_SYS_RESOURCE capabilities)
# can freely increase their value, but not decrease it below its initial
# settings.
#
# Values are used relative to the initial value of oom_score_adj when the server
# starts. Because typically the initial value is 0, they will often match the
# absolute values.
oom-score-adj-values 0 200 800
################################## SLOW LOG ###################################
# The Redis Slow Log is a system to log queries that exceeded a specified
# execution time. The execution time does not include the I/O operations
# like talking with the client, sending the reply and so forth,
# but just the time needed to actually execute the command (this is the only
# stage of command execution where the thread is blocked and can not serve
# other requests in the meantime).
#
# You can configure the slow log with two parameters: one tells Redis
# what is the execution time, in microseconds, to exceed in order for the
# command to get logged, and the other parameter is the length of the
# slow log. When a new command is logged the oldest one is removed from the
# queue of logged commands.
# The following time is expressed in microseconds, so 1000000 is equivalent
# to one second. Note that a negative number disables the slow log, while
# a value of zero forces the logging of every command.
slowlog-log-slower-than 10000
# There is no limit to this length. Just be aware that it will consume memory.
# You can reclaim memory used by the slow log with SLOWLOG RESET.
slowlog-max-len 128

View file

@ -1,142 +0,0 @@
# #ddev-generated
############################## MEMORY MANAGEMENT ################################
# Set a memory usage limit to the specified amount of bytes.
# When the memory limit is reached Redis will try to remove keys
# according to the eviction policy selected (see maxmemory-policy).
#
# If Redis can't remove keys according to the policy, or if the policy is
# set to 'noeviction', Redis will start to reply with errors to commands
# that would use more memory, like SET, LPUSH, and so on, and will continue
# to reply to read-only commands like GET.
#
# This option is usually useful when using Redis as an LRU or LFU cache, or to
# set a hard memory limit for an instance (using the 'noeviction' policy).
#
# WARNING: If you have replicas attached to an instance with maxmemory on,
# the size of the output buffers needed to feed the replicas are subtracted
# from the used memory count, so that network problems / resyncs will
# not trigger a loop where keys are evicted, and in turn the output
# buffer of replicas is full with DELs of keys evicted triggering the deletion
# of more keys, and so forth until the database is completely emptied.
#
# In short... if you have replicas attached it is suggested that you set a lower
# limit for maxmemory so that there is some free RAM on the system for replica
# output buffers (but this is not needed if the policy is 'noeviction').
#
maxmemory 512mb
# MAXMEMORY POLICY: how Redis will select what to remove when maxmemory
# is reached. You can select one from the following behaviors:
#
# volatile-lru -> Evict using approximated LRU, only keys with an expire set.
# allkeys-lru -> Evict any key using approximated LRU.
# volatile-lfu -> Evict using approximated LFU, only keys with an expire set.
# allkeys-lfu -> Evict any key using approximated LFU.
# volatile-random -> Remove a random key having an expire set.
# allkeys-random -> Remove a random key, any key.
# volatile-ttl -> Remove the key with the nearest expire time (minor TTL)
# noeviction -> Don't evict anything, just return an error on write operations.
#
# LRU means Least Recently Used
# LFU means Least Frequently Used
#
# Both LRU, LFU and volatile-ttl are implemented using approximated
# randomized algorithms.
#
# Note: with any of the above policies, Redis will return an error on write
# operations, when there are no suitable keys for eviction.
#
# At the date of writing these commands are: set setnx setex append
# incr decr rpush lpush rpushx lpushx linsert lset rpoplpush sadd
# sinter sinterstore sunion sunionstore sdiff sdiffstore zadd zincrby
# zunionstore zinterstore hset hsetnx hmset hincrby incrby decrby
# getset mset msetnx exec sort
#
# The default is:
#
maxmemory-policy allkeys-lru
# LRU, LFU and minimal TTL algorithms are not precise algorithms but approximated
# algorithms (in order to save memory), so you can tune it for speed or
# accuracy. By default Redis will check five keys and pick the one that was
# used least recently, you can change the sample size using the following
# configuration directive.
#
# The default of 5 produces good enough results. 10 Approximates very closely
# true LRU but costs more CPU. 3 is faster but not very accurate.
#
maxmemory-samples 4
# Redis reclaims expired keys in two ways: upon access when those keys are
# found to be expired, and also in background, in what is called the
# "active expire key". The key space is slowly and interactively scanned
# looking for expired keys to reclaim, so that it is possible to free memory
# of keys that are expired and will never be accessed again in a short time.
#
# The default effort of the expire cycle will try to avoid having more than
# ten percent of expired keys still in memory, and will try to avoid consuming
# more than 25% of total memory and to add latency to the system. However
# it is possible to increase the expire "effort" that is normally set to
# "1", to a greater value, up to the value "10". At its maximum value the
# system will use more CPU, longer cycles (and technically may introduce
# more latency), and will tolerate less already expired keys still present
# in the system. It's a tradeoff between memory, CPU and latency.
#
active-expire-effort 2
############################# LAZY FREEING ####################################
# Redis has two primitives to delete keys. One is called DEL and is a blocking
# deletion of the object. It means that the server stops processing new commands
# in order to reclaim all the memory associated with an object in a synchronous
# way. If the key deleted is associated with a small object, the time needed
# in order to execute the DEL command is very small and comparable to most other
# O(1) or O(log_N) commands in Redis. However if the key is associated with an
# aggregated value containing millions of elements, the server can block for
# a long time (even seconds) in order to complete the operation.
#
# For the above reasons Redis also offers non blocking deletion primitives
# such as UNLINK (non blocking DEL) and the ASYNC option of FLUSHALL and
# FLUSHDB commands, in order to reclaim memory in background. Those commands
# are executed in constant time. Another thread will incrementally free the
# object in the background as fast as possible.
#
# DEL, UNLINK and ASYNC option of FLUSHALL and FLUSHDB are user-controlled.
# It's up to the design of the application to understand when it is a good
# idea to use one or the other. However the Redis server sometimes has to
# delete keys or flush the whole database as a side effect of other operations.
# Specifically Redis deletes objects independently of a user call in the
# following scenarios:
#
# 1) On eviction, because of the maxmemory and maxmemory policy configurations,
# in order to make room for new data, without going over the specified
# memory limit.
# 2) Because of expire: when a key with an associated time to live (see the
# EXPIRE command) must be deleted from memory.
# 3) Because of a side effect of a command that stores data on a key that may
# already exist. For example the RENAME command may delete the old key
# content when it is replaced with another one. Similarly SUNIONSTORE
# or SORT with STORE option may delete existing keys. The SET command
# itself removes any old content of the specified key in order to replace
# it with the specified string.
# 4) During replication, when a replica performs a full resynchronization with
# its master, the content of the whole database is removed in order to
# load the RDB file just transferred.
#
# In all the above cases the default is to delete objects in a blocking way,
# like if DEL was called. However you can configure each case specifically
# in order to instead release memory in a non-blocking way like if UNLINK
# was called, using the following configuration directives.
lazyfree-lazy-eviction no
lazyfree-lazy-expire no
lazyfree-lazy-server-del no
replica-lazy-flush no
# It is also possible, for the case when to replace the user code DEL calls
# with UNLINK calls is not easy, to modify the default behavior of the DEL
# command to act exactly like UNLINK, using the following configuration
# directive:
lazyfree-lazy-user-del no

View file

@ -1,85 +0,0 @@
# #ddev-generated
################################## NETWORK #####################################
# By default, if no "bind" configuration directive is specified, Redis listens
# for connections from all available network interfaces on the host machine.
# It is possible to listen to just one or multiple selected interfaces using
# the "bind" configuration directive, followed by one or more IP addresses.
#
# Examples:
#
# bind 192.168.1.100 10.0.0.1
# bind 127.0.0.1 ::1
#
# ~~~ WARNING ~~~ If the computer running Redis is directly exposed to the
# internet, binding to all the interfaces is dangerous and will expose the
# instance to everybody on the internet. So by default we uncomment the
# following bind directive, that will force Redis to listen only on the
# IPv4 loopback interface address (this means Redis will only be able to
# accept client connections from the same host that it is running on).
#
# IF YOU ARE SURE YOU WANT YOUR INSTANCE TO LISTEN TO ALL THE INTERFACES
# JUST COMMENT OUT THE FOLLOWING LINE.
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
bind 0.0.0.0
# Protected mode is a layer of security protection, in order to avoid that
# Redis instances left open on the internet are accessed and exploited.
#
# When protected mode is on and if:
#
# 1) The server is not binding explicitly to a set of addresses using the
# "bind" directive.
# 2) No password is configured.
#
# The server only accepts connections from clients connecting from the
# IPv4 and IPv6 loopback addresses 127.0.0.1 and ::1, and from Unix domain
# sockets.
#
# By default protected mode is enabled. You should disable it only if
# you are sure you want clients from other hosts to connect to Redis
# even if no authentication is configured, nor a specific set of interfaces
# are explicitly listed using the "bind" directive.
protected-mode yes
# Accept connections on the specified port, default is 6379 (IANA #815344).
# If port 0 is specified Redis will not listen on a TCP socket.
port 6379
# TCP listen() backlog.
#
# In high requests-per-second environments you need a high backlog in order
# to avoid slow clients connection issues. Note that the Linux kernel
# will silently truncate it to the value of /proc/sys/net/core/somaxconn so
# make sure to raise both the value of somaxconn and tcp_max_syn_backlog
# in order to get the desired effect.
tcp-backlog 4096
# Unix socket.
#
# Specify the path for the Unix socket that will be used to listen for
# incoming connections. There is no default, so Redis will not listen
# on a unix socket when not specified.
#
# unixsocket /tmp/redis.sock
# unixsocketperm 700
# Close the connection after a client is idle for N seconds (0 to disable)
timeout 0
# TCP keepalive.
#
# If non-zero, use SO_KEEPALIVE to send TCP ACKs to clients in absence
# of communication. This is useful for two reasons:
#
# 1) Detect dead peers.
# 2) Force network equipment in the middle to consider the connection to be
# alive.
#
# On Linux, the specified value (in seconds) is the period used to send ACKs.
# Note that to close the connection the double of the time is needed.
# On other kernels the period depends on the kernel configuration.
#
# A reasonable value for this option is 300 seconds, which is the new
# Redis default starting with Redis 3.2.1.
tcp-keepalive 0

View file

@ -1,26 +0,0 @@
# #ddev-generated
################################## INCLUDES ###################################
# Network
include /etc/redis/conf/network.conf
# General
include /etc/redis/conf/general.conf
# Snapshots
include /etc/redis/conf/snapshots.conf
# Security
include /etc/redis/conf/security.conf
# Memory management
include /etc/redis/conf/memory.conf
# CPU management
include /etc/redis/conf/io.conf
# Append mode
include /etc/redis/conf/append.conf
# Advanced config
include /etc/redis/conf/advanced.conf

View file

@ -1,12 +0,0 @@
# #ddev-generated
################################## SECURITY ###################################
# Warning: since Redis is pretty fast, an outside user can try up to
# 1 million passwords per second against a modern box. This means that you
# should use very strong passwords, otherwise they will be very easy to break.
# Note that because the password is really a shared secret between the client
# and the server, and should not be memorized by any human, the password
# can be easily a long string from /dev/urandom or whatever, so by using a
# long and unguessable password no brute force attack will be possible.
user default ~* &* +@all on >redis
user redis ~* &* +@all on >redis

View file

@ -1,66 +0,0 @@
# #ddev-generated
################################ SNAPSHOTTING ################################
#
# Save the DB on disk:
#
# save <seconds> <changes>
#
# Will save the DB if both the given number of seconds and the given
# number of write operations against the DB occurred.
#
# In the example below the behavior will be to save:
# after 300 sec (5 min) if at least 1 key changed
# after 150 sec (2.5 min) if at least 10 keys changed
# after 30 sec if at least 10000 keys changed
#
# Note: you can disable saving completely by commenting out all "save" lines.
#
# It is also possible to remove all the previously configured save
# points by adding a save directive with a single empty string argument
# like in the following example:
#
# save ""
save 3600 1 300 100 60 10000
# By default Redis will stop accepting writes if RDB snapshots are enabled
# (at least one save point) and the latest background save failed.
# This will make the user aware (in a hard way) that data is not persisting
# on disk properly, otherwise chances are that no one will notice and some
# disaster will happen.
#
# If the background saving process will start working again Redis will
# automatically allow writes again.
#
# However if you have setup your proper monitoring of the Redis server
# and persistence, you may want to disable this feature so that Redis will
# continue to work as usual even if there are problems with disk,
# permissions, and so forth.
stop-writes-on-bgsave-error yes
# Compress string objects using LZF when dump .rdb databases?
# By default compression is enabled as it's almost always a win.
# If you want to save some CPU in the saving child set it to 'no' but
# the dataset will likely be bigger if you have compressible values or keys.
rdbcompression no
# Since version 5 of RDB a CRC64 checksum is placed at the end of the file.
# This makes the format more resistant to corruption but there is a performance
# hit to pay (around 10%) when saving and loading RDB files, so you can disable it
# for maximum performances.
#
# RDB files created with checksum disabled have a checksum of zero that will
# tell the loading code to skip the check.
rdbchecksum no
# The filename where to dump the DB
dbfilename haikuatelier.fr.rdb
# The working directory.
#
# The DB will be written inside this directory, with the filename specified
# above using the 'dbfilename' configuration directive.
#
# The Append Only File will also be created inside this directory.
#
# Note that you must specify a directory here, not a file name.
dir /data

View file

@ -1,57 +0,0 @@
<!doctype html>
<html lang="en">
<head>
<!-- #ddev-generated -->
<meta charset="UTF-8">
<meta
name="viewport"
content="width=device-width, initial-scale=1.0"
>
<title>vite not running</title>
<style>
html, body {
height: 100%;
margin: 0;
font-family:
-apple-system, BlinkMacSystemFont, avenir next, avenir, segoe ui, helvetica neue, helvetica, Cantarell,
Ubuntu, roboto, noto, arial, sans-serif;
}
body {
background: #ddd;
display: grid;
align-items: center;
justify-items: center;
}
h1 {
margin-top: 0;
}
main {
max-width: 36rem;
background: #fff;
padding: 1.5rem;
border: 1px #999 solid;
}
code {
font-family: Menlo, Consolas, Monaco, Liberation Mono, Lucida Console, monospace;
font-size: 180%;
color: #9499ff;
font-weight: bold;
}
</style>
</head>
<body>
<main>
<h1>vite not running</h1>
<p>
Apparently, you tried to access resources from the vite development server. However, the server is currently not
running.
</p>
<p>You can start the server by running the following command in your terminal:</p>
<code>ddev vite</code>
</main>
</body>
</html>

View file

@ -1,2 +0,0 @@
#ddev-generated
RUN a2enmod proxy_http

6
.dockerignore Normal file
View file

@ -0,0 +1,6 @@
*
!composer.json
!composer.lock
!config/*
!web/*
!wp-cli.yml

23
.gitignore vendored
View file

@ -5,16 +5,14 @@ web/app/mu-plugins/*/
web/app/themes/twentytwentyfour/
web/app/upgrade
web/app/cache/*
web/app/languages/
web/app/object-cache.php
# WordPress
web/wp
web/vendor
web/.htaccess
# Compilation
web/app/themes/haiku-atelier-2024/assets/js
web/app/themes/haiku-atelier-2024/assets/js/.vite/manifest.json
# Logs
*.log
@ -48,3 +46,20 @@ devenv.local.nix
# Gleam
build/
# Playwright
/test-results/
/playwright-report/
/blob-report/
/playwright/.cache/
# Containers
containers/data/*
containers/conf/angie/modules-available
containers/conf/angie/modules-enabled
containers/conf/angie/scripts
containers/conf/angie/snippets
# PHP et Twig
.php-cs-fixer.cache
.twig-cs-fixer.cache

View file

@ -10,32 +10,16 @@
"style": "warn",
"suspicious": "error"
},
"plugins": [
"eslint-plugin-jsdoc",
"eslint-plugin-promise",
"eslint-plugin-unicorn",
"jsdoc",
"oxc",
"oxc-security",
"promise",
"security",
"typescript",
"typescript-eslint",
"unicorn"
],
"plugins": ["jsdoc", "promise", "unicorn", "jsdoc", "oxc", "promise", "typescript", "unicorn"],
"rules": {
"eslint/max-classes-per-file": "off",
"eslint/no-magic-numbers": "off",
"eslint/no-redeclare": "off",
"import/export": "error",
"no-array-for-each": "off",
"no-async-await": "off",
"no-console": "off",
"no-magic-numbers": "off",
"no-magic-numbers": "warn",
"no-map-spread": "off",
"no-misused-promises": "off",
"no-optional-chaining": "off",
"no-redeclare": "off",
"no-rest-spread-properties": "off",
"no-ternary": "off",
"no-undefined": "off",
@ -48,8 +32,6 @@
"typescript/consistent-indexed-object-style": ["error", "record"],
"typescript/consistent-type-imports": "error",
"typescript/explicit-function-return-type": "warn",
"typescript/no-redeclare": ["off", { "ignoreDeclarationMerge": true }],
"unicorn/no-null": "off",
"unicorn/prefer-dom-node-dataset": "off",
"yoda": ["error", "never"]
}

1
.php-cs-fixer.cache Normal file

File diff suppressed because one or more lines are too long

262
.php-cs-fixer.dist.php Normal file
View file

@ -0,0 +1,262 @@
<?php declare(strict_types=1);
use PhpCsFixer\Config;
use PhpCsFixer\Finder;
use PhpCsFixer\Runner;
$finder = new Finder()->in(__DIR__)->exclude([
'containers',
'db',
'lib',
'tests',
'vendor',
'web/app/languages',
'web/app/mu-plugins',
'web/app/plugins',
'web/app/themes/twentytwentyfour',
'web/vendor',
'web/wp',
]);
return new Config()
->setRiskyAllowed(true)
->setRules([
'array_syntax' => ['syntax' => 'short'],
'assign_null_coalescing_to_coalesce_equal' => true,
'attribute_empty_parentheses' => ['use_parentheses' => true],
'blank_line_after_namespace' => true,
'blank_lines_before_namespace' => ['min_line_breaks' => 1, 'max_line_breaks' => 2],
'cast_spaces' => true,
'class_attributes_separation' => ['elements' => [
'case' => 'none',
'const' => 'none',
'method' => 'one',
'property' => 'one',
'trait_import' => 'none',
]],
'class_reference_name_casing' => true,
'clean_namespace' => true,
'combine_consecutive_issets' => true,
'combine_consecutive_unsets' => true,
'combine_nested_dirname' => true,
'comment_to_phpdoc' => true,
'constant_case' => true,
'date_time_immutable' => true,
'declare_equal_normalize' => true,
'declare_parentheses' => true,
'declare_strict_types' => true,
'dir_constant' => true,
'echo_tag_syntax' => true,
'encoding' => true,
'ereg_to_preg' => true,
'error_suppression' => true,
'explicit_indirect_variable' => true,
'explicit_string_variable' => true,
'final_class' => true,
'final_internal_class' => true,
'full_opening_tag' => true,
'fully_qualified_strict_types' => ['import_symbols' => true],
'function_to_constant' => true,
'global_namespace_import' => ['import_classes' => true, 'import_constants' => true, 'import_functions' => true],
'heredoc_to_nowdoc' => true,
'integer_literal_case' => true,
'lambda_not_used_import' => true,
'list_syntax' => true,
'logical_operators' => true,
'long_to_shorthand_operator' => true,
'lowercase_cast' => true,
'lowercase_keywords' => true,
'lowercase_static_reference' => true,
'magic_constant_casing' => true,
'magic_method_casing' => true,
'mb_str_functions' => true,
'modernize_strpos' => ['modernize_stripos' => true],
'modernize_types_casting' => true,
'modifier_keywords' => true,
'multiline_comment_opening_closing' => true,
'native_constant_invocation' => true,
'native_function_casing' => true,
'native_function_invocation' => true,
'native_type_declaration_casing' => true,
'new_expression_parentheses' => true,
'no_alias_functions' => ['sets' => ['@all']],
'no_alias_language_construct_call' => true,
'no_alternative_syntax' => true,
'no_binary_string' => true,
'no_closing_tag' => true,
'no_empty_comment' => true,
'no_homoglyph_names' => true,
'no_leading_import_slash' => true,
'no_mixed_echo_print' => ['use' => 'echo'],
'no_multiline_whitespace_around_double_arrow' => true,
'no_multiple_statements_per_line' => true,
'no_null_property_initialization' => true,
'no_php4_constructor' => true,
'no_short_bool_cast' => true,
'no_trailing_comma_in_singleline' => true,
'no_trailing_whitespace_in_comment' => true,
'no_unneeded_braces' => ['namespaces' => true],
'no_unneeded_control_parentheses' => ['statements' => [
'break',
'clone',
'continue',
'echo_print',
'negative_instanceof',
'others',
'return',
'switch_case',
'yield',
'yield_from',
]],
'no_unneeded_final_method' => true,
'no_unneeded_import_alias' => true,
'no_unreachable_default_argument_value' => true,
'no_unset_cast' => true,
'no_unset_on_property' => true,
'no_unused_imports' => true,
'no_useless_concat_operator' => true,
'no_useless_nullsafe_operator' => true,
'no_useless_printf' => true,
'no_useless_return' => true,
'no_useless_sprintf' => true,
'no_whitespace_before_comma_in_array' => ['after_heredoc' => true],
'non_printable_character' => true,
'normalize_index_brace' => true,
'nullable_type_declaration' => ['syntax' => 'union'],
'nullable_type_declaration_for_default_null_value' => true,
'numeric_literal_separator' => ['override_existing' => true, 'strategy' => 'use_separator'],
'ordered_attributes' => true,
'ordered_class_elements' => ['case_sensitive' => false, 'sort_algorithm' => 'alpha'],
'ordered_imports' => ['case_sensitive' => true],
'ordered_interfaces' => true,
'ordered_traits' => true,
'ordered_types' => ['null_adjustment' => 'always_last'],
'phpdoc_readonly_class_comment_to_keyword' => true,
'phpdoc_to_param_type' => true,
'phpdoc_to_property_type' => true,
'phpdoc_to_return_type' => true,
'pow_to_exponentiation' => true,
'protected_to_private' => true,
'psr_autoloading' => true,
'random_api_migration' => ['replacements' => [
'getrandmax' => 'mt_getrandmax',
'rand' => 'mt_rand',
'srand' => 'mt_srand',
]],
'return_assignment' => true,
'self_accessor' => true,
'self_static_accessor' => true,
'set_type_to_cast' => true,
'short_scalar_cast' => true,
'simple_to_complex_string_variable' => true,
'simplified_null_return' => true,
'single_class_element_per_statement' => true,
'single_import_per_statement' => true,
'single_line_after_imports' => true,
'single_line_comment_spacing' => true,
'single_line_comment_style' => true,
'single_line_empty_body' => true,
'single_trait_insert_per_statement' => true,
'standardize_not_equals' => true,
'static_lambda' => true,
'strict_comparison' => true,
'strict_param' => true,
'string_implicit_backslashes' => true,
'string_length_to_empty' => true,
'switch_continue_to_break' => true,
'ternary_to_null_coalescing' => true,
'trim_array_spaces' => true,
'use_arrow_functions' => true,
'void_return' => true,
'whitespace_after_comma_in_array' => ['ensure_single_space' => true],
// ---
// Each line of multi-line DocComments must have an asterisk [PSR-5] and must be aligned with the first one.
'align_multiline_comment' => ['comment_type' => 'all_multiline'],
// There should not be blank lines between docblock and the documented element.
'no_blank_lines_after_phpdoc' => true,
// There should not be empty PHPDoc blocks.
'no_empty_phpdoc' => true,
// Removes @param, @return and @var tags that don't provide any useful information.
'no_superfluous_phpdoc_tags' => [
'allow_hidden_params' => false,
'allow_mixed' => false,
'allow_unused_params' => false,
],
// PHPDoc should contain @param for all params.
'phpdoc_add_missing_param_annotation' => ['only_untyped' => false],
// All items of the given PHPDoc tags must be either left-aligned or (by default) aligned vertically.
'phpdoc_align' => true,
// PHPDoc annotation descriptions should not be a sentence.
'phpdoc_annotation_without_dot' => true,
// PHPDoc array<T> type must be used instead of T[].
'phpdoc_array_type' => true,
// Docblocks should have the same indentation as the documented subject.
'phpdoc_indent' => true,
// Fixes PHPDoc inline tags.
'phpdoc_inline_tag_normalizer' => true,
// Changes doc blocks from single to multi line, or reversed. Works for class constants, properties and methods only.
'phpdoc_line_span' => ['const' => 'single', 'method' => 'multi', 'property' => 'single'],
// PHPDoc list type must be used instead of array without a key.
'phpdoc_list_type' => true,
// @access annotations must be removed from PHPDoc.
'phpdoc_no_access' => true,
// No alias PHPDoc tags should be used.
'phpdoc_no_alias_tag' => true,
// @return void and @return null annotations must be removed from PHPDoc.
'phpdoc_no_empty_return' => false,
// @package and @subpackage annotations must be removed from PHPDoc.
'phpdoc_no_package' => true,
// Classy that does not inherit must not have @inheritdoc tags.
'phpdoc_no_useless_inheritdoc' => true,
// Annotations in PHPDoc should be ordered in defined sequence.
'phpdoc_order' => true,
// Order PHPDoc tags by value.
'phpdoc_order_by_value' => true,
// Orders all @param annotations in DocBlocks according to method signature.
'phpdoc_param_order' => true,
// The type of @return annotations of methods returning a reference to itself must the configured one.
'phpdoc_return_self_reference' => true,
// Scalar types should always be written in the same form. int not integer, bool not boolean, float not real or double.
'phpdoc_scalar' => ['types' => [
'boolean',
'callback',
'double',
'integer',
'never-return',
'never-returns',
'no-return',
'real',
'str',
]],
// Annotations in PHPDoc should be grouped together so that annotations of the same type immediately follow each other. Annotations of a different type are separated by a single blank line.
'phpdoc_separation' => [
'groups' => [
['Annotation', 'NamedArgumentConstructor', 'Target'],
['author', 'copyright', 'license'],
['category', 'package', 'subpackage'],
['property', 'property-read', 'property-write'],
['deprecated', 'link', 'see', 'since'],
],
'skip_unlisted_annotations' => false,
],
// Single line @var PHPDoc should have proper spacing.
'phpdoc_single_line_var_spacing' => true,
// PHPDoc summary should end in either a full stop, exclamation mark, or question mark.
'phpdoc_summary' => true,
// Docblocks should only be used on structural elements.
'phpdoc_to_comment' => ['allow_before_return_statement' => true],
// PHPDoc should start and end with content, excluding the very first and last line of the docblocks.
'phpdoc_trim' => true,
// Removes extra blank lines after summary and after description in PHPDoc.
'phpdoc_trim_consecutive_blank_line_separation' => true,
// The correct case must be used for standard PHP types in PHPDoc.
'phpdoc_types' => true,
// Sorts PHPDoc types.
'phpdoc_types_order' => ['null_adjustment' => 'always_last'],
// @var and @type annotations must have type and name in the correct order.
'phpdoc_var_annotation_correct_order' => true,
// @var and @type annotations of classy properties should not contain the name.
'phpdoc_var_without_name' => true,
])
->setFinder($finder)
->setParallelConfig(Runner\Parallel\ParallelConfigFactory::detect());

View file

@ -1,6 +1,6 @@
{
"$schema": "/opt/phpactor/phpactor.schema.json",
"language_server_phpstan.enabled": true,
"language_server_psalm.enabled": false,
"language_server_php_cs_fixer.enabled": false,
"language_server_phpstan.enabled": false,
"php_code_sniffer.enabled": false
}

31
.swcrc
View file

@ -1,31 +0,0 @@
{
"$schema": "https://swc.rs/schema.json",
"jsc": {
"externalHelpers": false,
"keepClassNames": false,
"loose": false,
"minify": {
"compress": true,
"mangle": true
},
"parser": {
"decorators": false,
"decoratorsBeforeExport": false,
"dynamicImport": false,
"exportDefaultFrom": false,
"exportNamespaceFrom": false,
"functionBind": false,
"importMeta": false,
"jsx": false,
"privateMethod": false,
"syntax": "typescript",
"topLevelAwait": false,
"tsx": false
},
"preserveAllComments": false,
"target": "es2020",
"transform": null
},
"minify": true,
"sourceMaps": true
}

1
.twig-cs-fixer.cache Normal file
View file

@ -0,0 +1 @@
{"php_version":"8.4.11","fixer_version":"866af065fd09980b6390ee5c69e45b08053101e8","rules":{"TwigCsFixer\\Rules\\Delimiter\\DelimiterSpacingRule":{"skipIfNewLine":true},"TwigCsFixer\\Rules\\Function\\MacroArgumentNameRule":{"case":"snake_case"},"TwigCsFixer\\Rules\\Function\\NamedArgumentNameRule":{"case":"snake_case"},"TwigCsFixer\\Rules\\Function\\NamedArgumentSeparatorRule":null,"TwigCsFixer\\Rules\\Function\\NamedArgumentSpacingRule":null,"TwigCsFixer\\Rules\\Operator\\OperatorNameSpacingRule":null,"TwigCsFixer\\Rules\\Operator\\OperatorSpacingRule":null,"TwigCsFixer\\Rules\\Punctuation\\PunctuationSpacingRule":{"before":{")":0,"]":0,"}":0,":":0,".":0,",":0,"|":0,"?:":0},"after":{"(":0,"[":0,"{":0,".":0,"|":0,":":1,",":1,"?:":1}},"TwigCsFixer\\Rules\\Variable\\VariableNameRule":{"case":"snake_case","optionalPrefix":""},"TwigCsFixer\\Rules\\Whitespace\\BlankEOFRule":null,"TwigCsFixer\\Rules\\Delimiter\\BlockNameSpacingRule":null,"TwigCsFixer\\Rules\\Whitespace\\EmptyLinesRule":null,"TwigCsFixer\\Rules\\Literal\\CompactHashRule":{"compact":false},"TwigCsFixer\\Rules\\Literal\\HashQuoteRule":{"useQuote":false},"TwigCsFixer\\Rules\\Function\\IncludeFunctionRule":null,"TwigCsFixer\\Rules\\Whitespace\\IndentRule":{"spaceRatio":4,"useTab":false},"TwigCsFixer\\Rules\\Literal\\SingleQuoteRule":{"skipStringContainingSingleQuote":true},"TwigCsFixer\\Rules\\Punctuation\\TrailingCommaMultiLineRule":{"comma":true},"TwigCsFixer\\Rules\\Punctuation\\TrailingCommaSingleLineRule":null,"TwigCsFixer\\Rules\\Whitespace\\TrailingSpaceRule":null},"hashes":{"web\/app\/themes\/haiku-atelier-2024\/views\/parts\/pages\/shop\/grille-produits.twig":"ef4ff046636044e452eeb3fe9edefaeb","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/pages\/produit\/grille-produits-similaires.twig":"eadf1a78a51084677aaaa56dafb1e708","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/pages\/produit\/informations-produit.twig":"4b7c756b4aa0f88942857e6c4969b354","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/pages\/produit\/photos-produit.twig":"5654c0382c5ef553a0b96a09194d909a","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/pages\/produit\/produits-similaires.twig":"695492c5926dfeeb69c37eb6227e1f18","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/pages\/panier\/panneau-informations-client.twig":"095a41b6e4142d7c2d9ebe18e4ac24d0","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/pages\/panier\/panneau-panier.twig":"684e37c3acba0ee0800421b635b3d515","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/pied-de-page.twig":"d5f5afaa90db1db6590ea0ed0584c216","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/bandeau.twig":"1164a4e9baafbb15be2a4dc98c32ced1","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/en-tete.twig":"1cf26fa4e64cdc7c6ed29b4e5627841a","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/html-head.twig":"691202d8b7719de34f604e42a74932af","web\/app\/themes\/haiku-atelier-2024\/views\/parts\/menu-categories-produits.twig":"e132a6035820545f704075ab9e89d119","web\/app\/themes\/haiku-atelier-2024\/views\/macros\/images.twig":"4beca7e03e55ef0e46828befcc779677","web\/app\/themes\/haiku-atelier-2024\/views\/404.twig":"75335b023fcc6f5c83197e8c126384e1","web\/app\/themes\/haiku-atelier-2024\/views\/a-propos.twig":"b5bdf0962e089bc93d33f5d23b97f64c","web\/app\/themes\/haiku-atelier-2024\/views\/accueil.twig":"beb4b2270ea3a1bcdbf8cd9e69f83ee7","web\/app\/themes\/haiku-atelier-2024\/views\/base.twig":"3e3ed592fb1c4bc8405be3b52f403725","web\/app\/themes\/haiku-atelier-2024\/views\/boutique.twig":"10449e7c29289282366d754ec3360589","web\/app\/themes\/haiku-atelier-2024\/views\/cgv.twig":"97984ba4344e2dcf8c3237796203c614","web\/app\/themes\/haiku-atelier-2024\/views\/contact.twig":"5d9dcae3e990c671404a8200b6c9815a","web\/app\/themes\/haiku-atelier-2024\/views\/echec-commande.twig":"9cf475c2c19664e9ef92a71e670b2880","web\/app\/themes\/haiku-atelier-2024\/views\/panier.twig":"6a423fea77a22c54e37fe8a7b6e1f34f","web\/app\/themes\/haiku-atelier-2024\/views\/produit.twig":"43bf608a266e8b8652a8f878fbe4580e","web\/app\/themes\/haiku-atelier-2024\/views\/succes-commande.twig":"712e54c1866a66988ccb1a79cbae53d6","web\/app\/themes\/haiku-atelier-2024\/woocommerce\/emails\/views\/email-commande-envoyee.twig":"e4e3bbc92a40eeae8925085b560dcb0d","web\/app\/themes\/haiku-atelier-2024\/woocommerce\/emails\/views\/email-base.twig":"7ef70033248d96d208f965dc4d885d9f","web\/app\/themes\/haiku-atelier-2024\/woocommerce\/emails\/views\/email-commande-recue.twig":"0b09e4586dd8eb4ca9513b9ae38e307b"}}

12
.twig-cs-fixer.php Normal file
View file

@ -0,0 +1,12 @@
<?php declare(strict_types=1);
use TwigCsFixer\Config\Config;
use TwigCsFixer\Ruleset\Ruleset;
use TwigCsFixer\Standard\TwigCsFixer;
$ruleset = new Ruleset()->addStandard(new TwigCsFixer());
$config = new Config()
->allowNonFixableRules()
->setRuleset($ruleset);
return $config;

15
.vscode/launch.json vendored
View file

@ -1,15 +0,0 @@
{
"configurations": [
{
"name": "Listen for Xdebug",
"type": "php",
"request": "launch",
"hostname": "0.0.0.0",
"port": 9003,
"pathMappings": { "/var/www/html": "${workspaceFolder}" },
"preLaunchTask": "DDEV: Enable Xdebug",
"postDebugTask": "DDEV: Disable Xdebug",
"skipFiles": ["**/vendor/**/*.php", "**/wp-admin/**/*.php", "**/wp-includes/**/*.php", "**/wp-blog-header.php"]
}
]
}

96
.vscode/settings.json vendored
View file

@ -1,96 +0,0 @@
{
"cSpell.words": [
"backorder",
"backordered",
"backorders",
"chaine",
"cliquée",
"controle",
"controles",
"coordonnee",
"cout",
"COUT",
"couts",
"Crell",
"defaut",
"defini",
"deplie",
"DERNIERE",
"echec",
"Ecoute",
"Ecouteurs",
"Eles",
"emet",
"Emetteurs",
"ENTETE",
"epingle",
"Epingle",
"EPINGLE",
"EPINGLES",
"etat",
"etats",
"ETATS",
"etendu",
"Evenements",
"exts",
"Fenetre",
"FENETRE",
"formatte",
"generique",
"geometricprecision",
"gere",
"glitchtip",
"GLITCHTIP",
"haikuabout",
"haikuatelier",
"idempotency",
"leve",
"methode",
"methodes",
"mobily",
"multiformats",
"paypal",
"phpstan",
"Planifiee",
"prenom",
"presentes",
"problemes",
"Proprietes",
"rafraichissement",
"rapprochee",
"recalcul",
"reinitialise",
"renseignables",
"reponse",
"requete",
"resultat",
"selecteur",
"selecteurs",
"Selectionne",
"Selectionnee",
"Separees",
"Simplifiee",
"souleve",
"specifiques",
"succes",
"Surchargement",
"tabpanel",
"tete",
"tseslint",
"Vali",
"VALIDEE",
"validite",
"Visibilite"
],
"djlint.pythonPath": "/home/gcch/.local/share/pipxu/venvs/8/bin/python",
"djlint.useVenv": false,
"stylelint.enable": true,
"stylelint.packageManager": "pnpm",
"twiggy.autoInsertSpaces": true,
"twiggy.framework": "ignore",
"twiggy.inlayHints.block": true,
"twiggy.inlayHints.macro": true,
"twiggy.inlayHints.macroArguments": true,
"typescript.tsdk": "node_modules/typescript/lib",
"terminal.integrated.env.osx": {}
}

17
.vscode/tasks.json vendored
View file

@ -1,17 +0,0 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "DDEV: Enable Xdebug",
"type": "shell",
"command": "ddev xdebug on",
"presentation": { "reveal": "silent", "close": true }
},
{
"label": "DDEV: Disable Xdebug",
"type": "shell",
"command": "ddev xdebug off",
"presentation": { "reveal": "silent", "close": true }
}
]
}

17
.zed/haa.txt Normal file
View file

@ -0,0 +1,17 @@
// {
// "languages": {
// "PHP": {
// "format_on_save": "on",
// "formatter": {
// "external": {
// "command": "mago",
// "arguments": ["format", "--stdin-input"] // "command": "bash",
// // "arguments": [
// // "-c",
// // "cat > /tmp/zed_php_cs_fixer && ./vendor/bin/php-cs-fixer fix --using-cache=no --quiet /tmp/zed_php_cs_fixer && cat /tmp/zed_php_cs_fixer"
// // ]
// }
// }
// }
// }
// }

View file

@ -1,6 +1,17 @@
// Folder-specific settings
//
// For a full list of overridable settings, and general information on folder-specific settings,
// see the documentation: https://zed.dev/docs/configuring-zed#settings-files
{
"language_servers": [
"!biome",
"!deno",
"!intelephense",
"!prettier",
"!tailwindcss-language-server",
"!vtsls",
"..."
],
"languages": {
"PHP": {
"format_on_save": "on",
"formatter": { "external": { "command": "mago", "arguments": ["format", "--stdin-input"] } }
}
}
}

View file

@ -1,29 +1,82 @@
{
"$schema": "https://biomejs.dev/schemas/1.9.4/schema.json",
"css": { "formatter": { "enabled": false }, "linter": { "enabled": true } },
"$schema": "https://biomejs.dev/schemas/2.0.4/schema.json",
"assist": {
"enabled": false
},
"css": {
"formatter": {
"enabled": false
},
"linter": {
"enabled": true
}
},
"files": {
"ignore": ["*.min.js", "vendor", "web/app/plugins", "web/app/themes/haiku-atelier-2024/assets", "web/wp"],
"experimentalScannerIgnores": [
"*.min.js",
"vendor",
"web/app/plugins",
"web/app/themes/haiku-atelier-2024/assets",
"web/wp"
],
"ignoreUnknown": true,
"maxSize": 100000000
},
"formatter": { "enabled": false },
"graphql": { "formatter": { "enabled": false }, "linter": { "enabled": true } },
"json": { "formatter": { "enabled": false }, "linter": { "enabled": true } },
"formatter": {
"enabled": false
},
"graphql": {
"formatter": {
"enabled": false
},
"linter": {
"enabled": true
}
},
"json": {
"formatter": {
"enabled": false
},
"linter": {
"enabled": true
}
},
"linter": {
"enabled": true,
"enabled": false,
"rules": {
"complexity": { "noForEach": "off" },
"complexity": {
"noForEach": "off"
},
"nursery": {
"recommended": true,
"useSortedClasses": {
"fix": "unsafe",
"level": "error",
"options": { "attributes": ["class"], "functions": [""] }
"options": {
"attributes": [
"class"
],
"functions": [
""
]
}
}
},
"style": { "recommended": true, "noNonNullAssertion": "off" },
"recommended": true
"recommended": true,
"style": {
"noInferrableTypes": "error",
"noNonNullAssertion": "off",
"noParameterAssign": "error",
"noUnusedTemplateLiteral": "error",
"noUselessElse": "error",
"recommended": true,
"useAsConstAssertion": "error",
"useDefaultParameterLast": "error",
"useEnumInitializers": "error",
"useNumberNamespace": "error",
"useSelfClosingElements": "error",
"useSingleVarDeclarator": "error"
}
}
},
"organizeImports": { "enabled": false }
}
}

2290
bun.lock

File diff suppressed because it is too large Load diff

161
compose.yaml Executable file
View file

@ -0,0 +1,161 @@
name: "haikuatelier.fr"
networks:
haiku-network:
services:
db:
container_name: "haikuatelier.fr-db"
env_file:
- path: "./.env"
required: true
healthcheck:
interval: "10s"
retries: 3
start_period: "60s"
test:
- "CMD"
- "healthcheck.sh"
- "--connect"
- "--innodb_initialized"
timeout: "5s"
image: "docker.io/library/mariadb:latest"
labels:
- "traefik.enable=false"
networks:
- "haiku-network"
restart: "unless-stopped"
volumes:
- "db-data:/var/lib/mysql:rw"
jaeger:
container_name: "haikuatelier.fr-jaeger"
environment:
- "COLLECTOR_OTLP_ENABLED=true"
healthcheck:
interval: "5s"
retries: 3
start_period: "5s"
test:
- "CMD"
- "wget"
- "--spider"
- "http://localhost:16686"
timeout: "2s"
image: "cr.jaegertracing.io/jaegertracing/jaeger:latest"
networks:
- "haiku-network"
ports:
- "6831:6831/udp"
- "6832:6832/udp"
- "5778:5778"
- "16686:16686"
- "4317:4317"
- "4318:4318"
- "14250:14250"
- "14268:14268"
- "14269:14269"
phpmyadmin:
container_name: "haikuatelier.fr-phpmyadmin"
depends_on:
- "db"
- "proxy"
- "traefik"
env_file:
- path: "./.env"
required: true
image: "docker.io/library/phpmyadmin:latest"
networks:
- "haiku-network"
ports:
- "127.0.0.1:8080:80"
restart: "on-failure:3"
proxy:
container_name: "haikuatelier.fr-proxy"
depends_on:
- "wordpress"
env_file:
- path: "./.env"
required: true
healthcheck:
interval: "10s"
retries: 3
test:
- "CMD-SHELL"
- "curl http://localhost/health | grep UP"
timeout: "5s"
image: "docker.io/eilandert/angie:latest"
networks:
- "haiku-network"
restart: "on-failure:3"
volumes:
- "./containers/conf/angie:/etc/angie:rw"
- "./containers/data/certs:/etc/angie/ssl:ro"
- "./containers/data/angie/logs:/var/log/angie:rw"
- "./:/var/www/wordpress:ro"
traefik:
container_name: "haikuatelier.fr-traefik"
env_file:
- path: "./.env"
required: true
healthcheck:
interval: "10s"
retries: 3
test:
- "CMD"
- "traefik"
- "healthcheck"
- "--ping"
timeout: "5s"
image: "traefik"
mem_limit: "256m"
mem_reservation: "128m"
networks:
- "haiku-network"
ports:
- "127.0.0.1:80:80"
- "127.0.0.1:443:443"
- "127.0.0.1:8082:8082"
restart: "unless-stopped"
volumes:
- "./containers/conf/traefik/dynamic:/etc/traefik/dynamic:ro"
- "./containers/conf/traefik/traefik.yaml:/etc/traefik/traefik.yml:ro"
- "./containers/data/certs:/etc/certs/:ro"
- "./containers/data/traefik/logs:/var/log/traefik:rw"
- "/var/run/user/1000/podman/podman.sock:/var/run/docker.sock:ro"
valkey:
command: "valkey-server /usr/local/etc/valkey/valkey.conf"
container_name: "haikuatelier.fr-valkey"
env_file:
- path: "./.env"
required: true
healthcheck:
interval: "10s"
retries: 3
test:
- "CMD-SHELL"
- "valkey-cli ping | grep PONG"
timeout: "5s"
image: "docker.io/valkey/valkey:9-alpine"
restart: "unless-stopped"
sysctls:
- "net.core.somaxconn=512"
volumes:
- "./containers/conf/valkey.conf:/usr/local/etc/valkey/valkey.conf:ro"
wordpress:
container_name: "haikuatelier.fr-wordpress"
depends_on:
- "db"
- "valkey"
- "traefik"
env_file:
- path: "./.env"
required: true
image: "localhost/wordpress-haiku-atelier"
networks:
- "haiku-network"
ports:
- "127.0.0.1:9000:9000"
restart: "unless-stopped"
volumes:
- "./containers/conf/php.ini:/usr/local/etc/php/conf.d/custom.ini:ro"
- "./:/var/www/wordpress:rw"
volumes:
db-data: null

View file

@ -1,82 +1,99 @@
{
"name": "roots/bedrock",
"type": "project",
"license": "MIT",
"description": "WordPress boilerplate with Composer, easier configuration, and an improved folder structure",
"homepage": "https://roots.io/bedrock/",
"authors": [
{ "name": "Scott Walkinshaw", "email": "scott.walkinshaw@gmail.com", "homepage": "https://github.com/swalkinshaw" },
{ "name": "Ben Word", "email": "ben@benword.com", "homepage": "https://github.com/retlehs" }
],
"keywords": ["bedrock", "composer", "roots", "wordpress", "wp", "wp-config"],
"support": {
"issues": "https://github.com/roots/bedrock/issues",
"forum": "https://discourse.roots.io/category/bedrock"
},
"repositories": [
{ "type": "composer", "url": "https://wpackagist.org", "only": ["wpackagist-plugin/*", "wpackagist-theme/*"] }
],
"require": {
"php": ">=8.2",
"composer/installers": "^2.3",
"crell/fp": "^1.0",
"htmlburger/carbon-fields": "^3.6.5",
"illuminate/support": "^12.18",
"laravel/helpers": "^1.7.1",
"log1x/wp-smtp": "^1.0.2",
"lstrojny/functional-php": "^1.17",
"mnsami/composer-custom-directory-installer": "^2.0",
"nesbot/carbon": "^3.8.2",
"oscarotero/env": "^2.1.1",
"ramsey/uuid": "^4.7.6",
"roots/bedrock-autoloader": "^1.0.4",
"roots/bedrock-disallow-indexing": "^2.0",
"roots/wordpress": "^6.8.1",
"roots/wp-config": "^1.0",
"stripe/stripe-php": "^16.3",
"symfony/uid": "^7.2.0",
"timber/timber": "^2.3",
"vlucas/phpdotenv": "^5.6.1",
"wpackagist-plugin/falcon": "^2.8.4",
"wpackagist-plugin/force-regenerate-thumbnails": "^2.2.1",
"wpackagist-plugin/query-monitor": "^3.17.0",
"wpackagist-plugin/redis-cache": "^2.5.4",
"wpackagist-plugin/wc-multishipping": "^2.5.4",
"wpackagist-plugin/woo-preview-emails": "^2.2.13",
"wpackagist-plugin/woocommerce": "^9.4.3",
"wpackagist-plugin/wp-mail-logging": "^1.13.1",
"wpackagist-plugin/wp-mail-smtp": "^4.2",
"wpackagist-plugin/wp-openapi": "^1.0.16",
"wpackagist-theme/twentytwentyfour": "^1.3"
},
"require-dev": {
"phpstan/extension-installer": "^1.4.3",
"phpstan/phpstan": "^2.0.3",
"roave/security-advisories": "dev-latest",
"squizlabs/php_codesniffer": "^3.11.1",
"szepeviktor/phpstan-wordpress": "2.x-dev"
"authors": [],
"autoload": {
"psr-4": {
"HaikuAtelier\\": "web/app/themes/haiku-atelier-2024/src/inc"
}
},
"config": {
"optimize-autoloader": true,
"preferred-install": "dist",
"allow-plugins": {
"carthage-software/mago": true,
"composer/installers": true,
"mnsami/composer-custom-directory-installer": true,
"roots/wordpress-core-installer": true,
"phpstan/extension-installer": true
"phpstan/extension-installer": true,
"roots/wordpress-core-installer": true
},
"optimize-autoloader": true,
"preferred-install": "dist",
"sort-packages": true
},
"minimum-stability": "dev",
"prefer-stable": true,
"extra": {
"installer-paths": {
"web/vendor/{$vendor}/{$name}": ["htmlburger/carbon-fields"],
"web/app/mu-plugins/{$name}/": ["type:wordpress-muplugin"],
"web/app/plugins/{$name}/": ["type:wordpress-plugin"],
"web/app/themes/{$name}/": ["type:wordpress-theme"]
"web/app/mu-plugins/{$name}/": [
"type:wordpress-muplugin"
],
"web/app/plugins/{$name}/": [
"type:wordpress-plugin"
],
"web/app/themes/{$name}/": [
"type:wordpress-theme"
],
"web/vendor/{$vendor}/{$name}": [
"htmlburger/carbon-fields"
]
},
"wordpress-install-dir": "web/wp"
},
"scripts": { "test": ["phpcs"] }
"minimum-stability": "dev",
"name": "gcch/haiku-atelier",
"prefer-stable": true,
"repositories": [
{
"only": [
"wpackagist-plugin/*",
"wpackagist-theme/*"
],
"type": "composer",
"url": "https://wpackagist.org"
}
],
"require": {
"composer/installers": "^2.3",
"crell/fp": "^1.0",
"htmlburger/carbon-fields": "^3.6.9",
"illuminate/support": "^12.37",
"laravel/helpers": "^1.8.1",
"log1x/wp-smtp": "^1.0.2",
"lstrojny/functional-php": "^1.17",
"mnsami/composer-custom-directory-installer": "^2.0",
"mrottow/vite-wordpress": "^0.1.3",
"nesbot/carbon": "^3.10.3",
"oscarotero/env": "^2.1.1",
"php": ">=8.4",
"ramsey/uuid": "^4.9.1",
"roots/bedrock-autoloader": "^1.0.4",
"roots/bedrock-disallow-indexing": "^2.0",
"roots/wordpress": "^6.8.3",
"roots/wp-config": "^1.0",
"stripe/stripe-php": "^16.6",
"symfony/uid": "^8",
"timber/timber": "^2.3.3",
"vlucas/phpdotenv": "^5.6.2",
"webmozart/assert": "^1.12.1",
"wpackagist-plugin/falcon": "2.8.6",
"wpackagist-plugin/force-regenerate-thumbnails": "2.2.2",
"wpackagist-plugin/query-monitor": "^3.20.0",
"wpackagist-plugin/redis-cache": "^2.7.0",
"wpackagist-plugin/wc-multishipping": "3.0",
"wpackagist-plugin/woo-preview-emails": "2.2.14",
"wpackagist-plugin/woocommerce": "10.3.6",
"wpackagist-plugin/wp-mail-logging": "1.15.0",
"wpackagist-plugin/wp-mail-smtp": "4.7.1",
"wpackagist-plugin/wp-openapi": "1.0.27",
"wpackagist-theme/twentytwentyfour": "^1.4"
},
"require-dev": {
"friendsofphp/php-cs-fixer": "^3.89.2",
"phpstan/extension-installer": "^1.4.3",
"phpstan/phpstan": "^2.1.32",
"phpstan/phpstan-deprecation-rules": "^2.0.3",
"phpstan/phpstan-webmozart-assert": "^2.0",
"rector/rector": "^2.2.7",
"roave/security-advisories": "dev-latest",
"squizlabs/php_codesniffer": "^4.0.1",
"swissspidy/phpstan-no-private": "^1.0",
"szepeviktor/phpstan-wordpress": "2.x-dev",
"vincentlanglet/twig-cs-fixer": "^3.10"
},
"type": "project"
}

3493
composer.lock generated Executable file → Normal file

File diff suppressed because it is too large Load diff

View file

@ -1,4 +1,5 @@
<?php
/**
* Your base production configuration goes in this file. Environment-specific
* overrides go in their respective config/environments/{{WP_ENV}}.php file.
@ -8,153 +9,139 @@
* can.
*/
use Roots\WPConfig\Config;
declare(strict_types=1);
use function Env\env;
use Roots\WPConfig\Config;
// USE_ENV_ARRAY + CONVERT_* + STRIP_QUOTES
Env\Env::$options = 31;
/**
* Directory containing all of the site's files
* Directory containing all of the site's files.
*
* @var string
*/
$root_dir = dirname(__DIR__);
$root_dir = \dirname(__DIR__);
/**
* Document Root
* Document Root.
*
* @var string
*/
$webroot_dir = $root_dir . "/web";
$webroot_dir = $root_dir . '/web';
/**
/*
* Use Dotenv to set required environment variables and load .env file in root
* .env.local will override .env if it exists
*/
if (file_exists($root_dir . "/.env")) {
$env_files = file_exists($root_dir . "/.env.local") ? [".env", ".env.local"] : [".env"];
if (file_exists($root_dir . '/.env')) {
$env_files = file_exists($root_dir . '/.env.local')
? ['.env', '.env.local']
: ['.env'];
$dotenv = Dotenv\Dotenv::createImmutable($root_dir, $env_files, false);
$dotenv = Dotenv\Dotenv::createImmutable($root_dir, $env_files, false);
$dotenv->load();
$dotenv->load();
$dotenv->required(["WP_HOME", "WP_SITEURL"]);
if (!env("DATABASE_URL")) {
$dotenv->required(["DB_NAME", "DB_USER", "DB_PASSWORD"]);
}
$dotenv->required(['WP_HOME', 'WP_SITEURL']);
if (!env('DATABASE_URL')) {
$dotenv->required(['DB_NAME', 'DB_USER', 'DB_PASSWORD']);
}
}
/**
/*
* Set up our global environment constant and load its config first
* Default: production
*/
define("WP_ENV", env("WP_ENV") ?: "production");
\define('WP_ENV', env('WP_ENV') ?: 'production');
/**
* Infer WP_ENVIRONMENT_TYPE based on WP_ENV
*/
if (!env("WP_ENVIRONMENT_TYPE") && in_array(WP_ENV, ["production", "staging", "development", "local"])) {
Config::define("WP_ENVIRONMENT_TYPE", WP_ENV);
// Infer WP_ENVIRONMENT_TYPE based on WP_ENV
if (!env('WP_ENVIRONMENT_TYPE') && \in_array(WP_ENV, ['production', 'staging', 'development', 'local'], true)) {
Config::define('WP_ENVIRONMENT_TYPE', WP_ENV);
}
/**
* URLs
*/
Config::define("WP_HOME", env("WP_HOME"));
Config::define("WP_SITEURL", env("WP_SITEURL"));
// URLs
Config::define('WP_HOME', env('WP_HOME'));
Config::define('WP_SITEURL', env('WP_SITEURL'));
/**
* Custom Content Directory
*/
Config::define("CONTENT_DIR", "/app");
Config::define("WP_CONTENT_DIR", $webroot_dir . Config::get("CONTENT_DIR"));
Config::define("WP_CONTENT_URL", Config::get("WP_HOME") . Config::get("CONTENT_DIR"));
// Custom Content Directory
Config::define('CONTENT_DIR', '/app');
Config::define('WP_CONTENT_DIR', $webroot_dir . Config::get('CONTENT_DIR'));
Config::define('WP_CONTENT_URL', Config::get('WP_HOME') . Config::get('CONTENT_DIR'));
/**
* DB settings
*/
if (env("DB_SSL")) {
Config::define("MYSQL_CLIENT_FLAGS", MYSQLI_CLIENT_SSL);
// DB settings
if (env('DB_SSL')) {
Config::define('MYSQL_CLIENT_FLAGS', \MYSQLI_CLIENT_SSL);
}
Config::define("DB_NAME", env("DB_NAME"));
Config::define("DB_USER", env("DB_USER"));
Config::define("DB_PASSWORD", env("DB_PASSWORD"));
Config::define("DB_HOST", env("DB_HOST") ?: "localhost");
Config::define("DB_CHARSET", "utf8mb4");
Config::define("DB_COLLATE", "");
$table_prefix = env("DB_PREFIX") ?: "wp_";
Config::define('DB_NAME', env('DB_NAME'));
Config::define('DB_USER', env('DB_USER'));
Config::define('DB_PASSWORD', env('DB_PASSWORD'));
Config::define('DB_HOST', env('DB_HOST') ?: 'localhost');
Config::define('DB_CHARSET', 'utf8mb4');
Config::define('DB_COLLATE', '');
$table_prefix = env('DB_PREFIX') ?: 'wp_';
if (env("DATABASE_URL")) {
$dsn = (object) parse_url(env("DATABASE_URL"));
if (env('DATABASE_URL')) {
$dsn = (object) parse_url(env('DATABASE_URL'));
Config::define("DB_NAME", substr($dsn->path, 1));
Config::define("DB_USER", $dsn->user);
Config::define("DB_PASSWORD", isset($dsn->pass) ? $dsn->pass : null);
Config::define("DB_HOST", isset($dsn->port) ? "{$dsn->host}:{$dsn->port}" : $dsn->host);
Config::define('DB_NAME', mb_substr($dsn->path, 1));
Config::define('DB_USER', $dsn->user);
Config::define('DB_PASSWORD', $dsn->pass ?? null);
Config::define('DB_HOST', isset($dsn->port) ? "{$dsn->host}:{$dsn->port}" : $dsn->host);
}
/**
* Authentication Unique Keys and Salts
*/
Config::define("AUTH_KEY", env("AUTH_KEY"));
Config::define("SECURE_AUTH_KEY", env("SECURE_AUTH_KEY"));
Config::define("LOGGED_IN_KEY", env("LOGGED_IN_KEY"));
Config::define("NONCE_KEY", env("NONCE_KEY"));
Config::define("AUTH_SALT", env("AUTH_SALT"));
Config::define("SECURE_AUTH_SALT", env("SECURE_AUTH_SALT"));
Config::define("LOGGED_IN_SALT", env("LOGGED_IN_SALT"));
Config::define("NONCE_SALT", env("NONCE_SALT"));
// Authentication Unique Keys and Salts
Config::define('AUTH_KEY', env('AUTH_KEY'));
Config::define('SECURE_AUTH_KEY', env('SECURE_AUTH_KEY'));
Config::define('LOGGED_IN_KEY', env('LOGGED_IN_KEY'));
Config::define('NONCE_KEY', env('NONCE_KEY'));
Config::define('AUTH_SALT', env('AUTH_SALT'));
Config::define('SECURE_AUTH_SALT', env('SECURE_AUTH_SALT'));
Config::define('LOGGED_IN_SALT', env('LOGGED_IN_SALT'));
Config::define('NONCE_SALT', env('NONCE_SALT'));
/**
* Custom Settings
*/
Config::define("AUTOMATIC_UPDATER_DISABLED", true);
Config::define("DISABLE_WP_CRON", env("DISABLE_WP_CRON") ?: false);
// Custom Settings
Config::define('AUTOMATIC_UPDATER_DISABLED', true);
Config::define('DISABLE_WP_CRON', env('DISABLE_WP_CRON') ?: false);
// Disable the plugin and theme file editor in the admin
Config::define("DISALLOW_FILE_EDIT", true);
Config::define('DISALLOW_FILE_EDIT', true);
// Disable plugin and theme updates and installation from the admin
Config::define("DISALLOW_FILE_MODS", true);
Config::define('DISALLOW_FILE_MODS', true);
// Limit the number of post revisions
Config::define("WP_POST_REVISIONS", env("WP_POST_REVISIONS") ?? true);
Config::define('WP_POST_REVISIONS', env('WP_POST_REVISIONS') ?? true);
/**
* Debugging Settings
*/
Config::define("WP_DEBUG_DISPLAY", false);
Config::define("WP_DEBUG_LOG", false);
Config::define("SCRIPT_DEBUG", false);
ini_set("display_errors", "0");
// Debugging Settings
Config::define('WP_DEBUG_DISPLAY', false);
Config::define('WP_DEBUG_LOG', false);
Config::define('SCRIPT_DEBUG', false);
ini_set('display_errors', '0');
/**
* Plugins
*/
Config::define("WPMU_PLUGIN_DIR", Config::get("WP_CONTENT_DIR") . "/mu-plugins");
Config::define("WP_PLUGIN_DIR", Config::get("WP_CONTENT_DIR") . "/plugins");
// Plugins
Config::define('WPMU_PLUGIN_DIR', Config::get('WP_CONTENT_DIR') . '/mu-plugins');
Config::define('WP_PLUGIN_DIR', Config::get('WP_CONTENT_DIR') . '/plugins');
/**
/*
* Allow WordPress to detect HTTPS when used behind a reverse proxy or a load balancer
* See https://codex.wordpress.org/Function_Reference/is_ssl#Notes
*/
if (isset($_SERVER["HTTP_X_FORWARDED_PROTO"]) && $_SERVER["HTTP_X_FORWARDED_PROTO"] === "https") {
$_SERVER["HTTPS"] = "on";
if (isset($_SERVER['HTTP_X_FORWARDED_PROTO']) && 'https' === $_SERVER['HTTP_X_FORWARDED_PROTO']) {
$_SERVER['HTTPS'] = 'on';
}
$env_config = __DIR__ . "/environments/" . WP_ENV . ".php";
$env_config = __DIR__ . '/environments/' . WP_ENV . '.php';
if (file_exists($env_config)) {
require_once $env_config;
include_once $env_config;
}
Config::apply();
/**
* Bootstrap WordPress
*/
if (!defined("ABSPATH")) {
define("ABSPATH", $webroot_dir . "/wp/");
// Bootstrap WordPress
if (!\defined('ABSPATH')) {
\define('ABSPATH', $webroot_dir . '/wp/');
}

View file

@ -1,35 +1,36 @@
<?php
/**
* Configuration overrides for WP_ENV === 'development'
* Configuration overrides for WP_ENV === 'development'.
*/
declare(strict_types=1);
use Roots\WPConfig\Config;
use function Env\env;
use Roots\WPConfig\Config;
Config::define("SAVEQUERIES", true);
Config::define("WP_DEBUG", true);
Config::define("WP_DEBUG_DISPLAY", false);
Config::define("WP_DEBUG_LOG", env("WP_DEBUG_LOG") ?? true);
Config::define("WP_DISABLE_FATAL_ERROR_HANDLER", true);
Config::define("SCRIPT_DEBUG", true);
Config::define("DISALLOW_INDEXING", true);
ini_set("display_errors", "1");
Config::define('SAVEQUERIES', true);
Config::define('WP_DEBUG', true);
Config::define('WP_DEBUG_DISPLAY', true);
Config::define('WP_DEBUG_LOG', env('WP_DEBUG_LOG') ?? true);
Config::define('WP_DISABLE_FATAL_ERROR_HANDLER', true);
Config::define('SCRIPT_DEBUG', true);
Config::define('DISALLOW_INDEXING', true);
ini_set('display_errors', '1');
// Enable plugin and theme updates and installation from the admin
Config::define("DISALLOW_FILE_MODS", false);
Config::define('DISALLOW_FILE_MODS', false);
// WooCommerce
Config::define("WOOCOMMERCE_API_CONSUMER_KEY", env("WOOCOMMERCE_API_CONSUMER_KEY"));
Config::define("WOOCOMMERCE_API_CONSUMER_SECRET", env("WOOCOMMERCE_API_CONSUMER_SECRET"));
Config::define('WOOCOMMERCE_API_CONSUMER_KEY', env('WOOCOMMERCE_API_CONSUMER_KEY'));
Config::define('WOOCOMMERCE_API_CONSUMER_SECRET', env('WOOCOMMERCE_API_CONSUMER_SECRET'));
// Stripe
Config::define("STRIPE_API_SECRET", env("STRIPE_API_SECRET"));
Config::define('STRIPE_API_SECRET', env('STRIPE_API_SECRET'));
// Redis
Config::define("WP_REDIS_HOST", env("WP_REDIS_HOST"));
Config::define("WP_REDIS_PASSWORD", env("WP_REDIS_PASSWORD"));
Config::define('WP_REDIS_HOST', env('WP_REDIS_HOST'));
Config::define('WP_REDIS_PASSWORD', env('WP_REDIS_PASSWORD'));
// Désactive la mise à jour des traductions automatiques
Config::define("WP_AUTO_UPDATE_TRANSLATION", false);
Config::define('WP_AUTO_UPDATE_TRANSLATION', false);

View file

@ -1,23 +1,24 @@
<?php
/**
* Configuration overrides for WP_ENV === 'production'
* Configuration overrides for WP_ENV === 'production'.
*/
declare(strict_types=1);
use Roots\WPConfig\Config;
use function Env\env;
use Roots\WPConfig\Config;
Config::define("WP_DEBUG", true);
Config::define("WP_DEBUG_DISPLAY", false);
Config::define("WP_DEBUG_LOG", env("WP_DEBUG_LOG") ?? true);
Config::define("WP_DISABLE_FATAL_ERROR_HANDLER", false);
Config::define('WP_DEBUG', true);
Config::define('WP_DEBUG_DISPLAY', false);
Config::define('WP_DEBUG_LOG', env('WP_DEBUG_LOG') ?? true);
Config::define('WP_DISABLE_FATAL_ERROR_HANDLER', false);
Config::define("DISALLOW_INDEXING", false);
Config::define("DISALLOW_FILE_MODS", false);
Config::define('DISALLOW_INDEXING', false);
Config::define('DISALLOW_FILE_MODS', false);
Config::define("WOOCOMMERCE_API_CONSUMER_KEY", env("WOOCOMMERCE_API_CONSUMER_KEY"));
Config::define("WOOCOMMERCE_API_CONSUMER_SECRET", env("WOOCOMMERCE_API_CONSUMER_SECRET"));
Config::define('WOOCOMMERCE_API_CONSUMER_KEY', env('WOOCOMMERCE_API_CONSUMER_KEY'));
Config::define('WOOCOMMERCE_API_CONSUMER_SECRET', env('WOOCOMMERCE_API_CONSUMER_SECRET'));
// Stripe
Config::define("STRIPE_API_SECRET", env("STRIPE_API_SECRET"));
Config::define('STRIPE_API_SECRET', env('STRIPE_API_SECRET'));

View file

@ -1,13 +1,14 @@
<?php
/**
* Configuration overrides for WP_ENV === 'staging'
* Configuration overrides for WP_ENV === 'staging'.
*/
declare(strict_types=1);
use Roots\WPConfig\Config;
use function Env\env;
use Roots\WPConfig\Config;
Config::define("DISALLOW_INDEXING", true);
Config::define("WOOCOMMERCE_API_CONSUMER_KEY", env("WOOCOMMERCE_API_CONSUMER_KEY"));
Config::define("WOOCOMMERCE_API_CONSUMER_SECRET", env("WOOCOMMERCE_API_CONSUMER_SECRET"));
Config::define('DISALLOW_INDEXING', true);
Config::define('WOOCOMMERCE_API_CONSUMER_KEY', env('WOOCOMMERCE_API_CONSUMER_KEY'));
Config::define('WOOCOMMERCE_API_CONSUMER_SECRET', env('WOOCOMMERCE_API_CONSUMER_SECRET'));

45
containers/Dockerfile Normal file
View file

@ -0,0 +1,45 @@
# syntax=docker/dockerfile:1
FROM docker.io/library/alpine:latest AS repo
# Ajoute Git.
RUN set -eux && apk add --no-cache \
bash \
git \
;
# Récupère les fichiers du site pour la branche « Production ».
RUN git clone --branch production --depth 1 http://git.gcch.fr/gcch/haiku-atelier-2024.git "/tmp/repo"
FROM docker.io/library/wordpress:php8.5-fpm-alpine AS php
ENTRYPOINT []
LABEL org.opencontainers.image.title=wordpress-haiku-atelier \
org.opencontainers.image.description="WordPress pour Haiku Atelier" \
org.opencontainers.image.authors="gcch" \
org.opencontainers.image.vendor="gcch" \
org.opencontainers.image.licenses=AGPL-3.0
# Installe wp-cli.
RUN curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar && chmod +x wp-cli.phar && mv wp-cli.phar /usr/local/bin/wp
# Installe Composer.
RUN php -r "copy('https://getcomposer.org/installer', './composer-setup.php');" && php ./composer-setup.php && mv composer.phar /usr/local/bin/composer && rm composer-setup.php
RUN set -eux && apk add --no-cache \
fish \
ghostscript \
imagemagick \
mariadb-client \
;
VOLUME /var/www/wordpress
WORKDIR /var/www/wordpress
# Récupère les fichiers du projet.
COPY --from=repo --chmod=777 "/tmp/repo/" .
# Installe les dépendences Composer.
RUN composer install
EXPOSE 9000
CMD ["php-fpm"]

Some files were not shown because too many files have changed in this diff Show more