-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy path.lando.yml
60 lines (60 loc) · 2.14 KB
/
.lando.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: shortcode-widget
recipe: wordpress
config:
php: "8.2"
webroot: wordpress
# Keep it empty, to enable xdebug use `lando xdebug <xdebug mode>` instead
xdebug: ""
config:
php: .lando/php.ini
database: .lando/mysql.cnf
services:
node:
type: node:18
overrides:
environment:
NODE_ENV: "development"
appserver:
overrides:
environment:
# Support debugging Drush with XDEBUG.
PHP_IDE_CONFIG: "serverName=appserver"
PROFILER_OUTPUT_DIR: "profiler-output" # If changing this value, change in .gitignore also
volumes:
- '.lando/wp-cli.yml:/wp-cli.yml'
- '.:/app/wordpress/wp-content/plugins/shortcode-widget'
- '/app/wordpress/wp-content/plugins/shortcode-widget/wordpress'
- '/app/wordpress/wp-content/plugins/shortcode-widget/node_modules'
build:
- wp core download --force --skip-content
run:
- sleep 5 # For some reason, we have to wait at least a second till database is up.
- | # Create WordPress config file and add necessary constants and custom config
wp config create --dbhost=database --dbname=wordpress --dbuser=wordpress --dbpass=wordpress --dbprefix=wp_ --force
- wp config set WP_DISABLE_FATAL_ERROR_HANDLER true --raw
- wp config set WP_DEBUG true --raw
- wp config set WP_DEBUG_LOG true --raw
- wp config set WP_DEBUG_DISPLAY false --raw
- wp config set AUTOMATIC_UPDATER_DISABLED true --raw
- wp config set DISALLOW_FILE_EDIT true --raw
- wp config set WP_ENVIRONMENT_TYPE 'local'
- | # Let's check if WordPress is not installed, then install it
if ! wp core is-installed; then
wp core install --url=https://$LANDO_APP_NAME.$LANDO_DOMAIN \
--title=$LANDO_APP_NAME \
--admin_user=admin \
--admin_password=password \
--skip-email
wp theme install --activate twentytwentyone
fi
tooling:
xdebug:
description: Loads Xdebug in the selected mode.
cmd:
- appserver: /app/.lando/xdebug.sh
user: root
node:
service: node
npm:
service: node