forked from krakazyabra/wordpress-ols-php8-docker
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsetup_docker.sh
More file actions
30 lines (24 loc) · 733 Bytes
/
setup_docker.sh
File metadata and controls
30 lines (24 loc) · 733 Bytes
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
#!/usr/bin/env bash
DEFAULT_VH_ROOT='/var/www/vhosts'
DOMAIN=$URL
echo "listener HTTP {
address 10.0.192.16:80
secure 0
}
listener HTTPS {
address 10.0.192.16:443
secure 1
keyFile /usr/local/lsws/admin/conf/webadmin.key
certFile /usr/local/lsws/admin/conf/webadmin.crt
}
vhTemplate docker {
templateFile conf/templates/docker.conf
listeners HTTP, HTTPS
note docker
member $DOMAIN {
vhDomain $DOMAIN, *
}
}
" >> /usr/local/lsws/conf/httpd_config.conf
mkdir -p $DEFAULT_VH_ROOT/$DOMAIN/{html,logs,certs}
chown 1000:1000 $DEFAULT_VH_ROOT/$DOMAIN/ -R