generated from ddev/ddev-addon-template
-
-
Notifications
You must be signed in to change notification settings - Fork 7
/
install.yaml
33 lines (29 loc) · 1.18 KB
/
install.yaml
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
name: xhgui
project_files:
- docker-compose.xhgui.yaml
- docker-compose.xhgui_norouter.yaml
- config.xhgui.yaml
- commands/host/xhgui
- xhgui/Dockerfile
- xhgui/xhgui.config.php
- xhgui/collector/xhgui.collector.config.php
- xhgui/collector/xhgui.collector.php
- xhgui/nginx.conf
pre_install_actions:
# Ensure we're on DDEV 1.23+. It's required for the `xhgui` command (launch by port).
- |
#ddev-nodisplay
#ddev-description:Checking DDEV version
(ddev debug capabilities | grep corepack >/dev/null) || (echo "Please upgrade DDEV to v1.23+ to enable launching." && false)
post_install_actions:
- |
#ddev-description:If router disabled, directly expose port
#
if ( {{ contains "ddev-router" (list .DdevGlobalConfig.omit_containers | toString) }} ); then
printf "#ddev-generated\nservices:\n xhgui:\n ports:\n - 8143:80\n" > docker-compose.xhgui_norouter.yaml
fi
- |
echo "You can now use 'ddev xhgui' to launch XHGui"
removal_actions:
- if [[ "$DDEV_DATABASE_FAMILY" == "postgres" ]]; then ddev psql -U db -c "drop database xhgui"; fi
- if [[ "$DDEV_DATABASE_FAMILY" != "postgres" ]]; then ddev mysql -uroot -proot -e "DROP DATABASE IF EXISTS xhgui"; fi