forked from kimhyungsik/ax_hub_mcp_tool
Add deployment scripts and docker-compose configs for OCI
This commit is contained in:
30
setup_apache.sh
Normal file
30
setup_apache.sh
Normal file
@@ -0,0 +1,30 @@
|
||||
#!/bin/bash
|
||||
|
||||
# Apache configuration setup for DAP-MCP
|
||||
|
||||
create_vhost() {
|
||||
local domain=$1
|
||||
local port=$2
|
||||
local conf_file="/etc/apache2/sites-available/${domain}.conf"
|
||||
|
||||
echo "<VirtualHost *:80>
|
||||
ServerName ${domain}
|
||||
|
||||
ProxyPreserveHost On
|
||||
ProxyPass / http://127.0.0.1:${port}/
|
||||
ProxyPassReverse / http://127.0.0.1:${port}/
|
||||
|
||||
ErrorLog \${APACHE_LOG_DIR}/${domain}_error.log
|
||||
CustomLog \${APACHE_LOG_DIR}/${domain}_access.log combined
|
||||
</VirtualHost>" > "$conf_file"
|
||||
|
||||
a2ensite "${domain}.conf"
|
||||
}
|
||||
|
||||
create_vhost "mcp.devjun.net" "9281"
|
||||
create_vhost "tool-sal.devjun.net" "9282"
|
||||
create_vhost "tool-cus.devjun.net" "9284"
|
||||
create_vhost "tool-pro.devjun.net" "9285"
|
||||
create_vhost "tool-sys.devjun.net" "9286"
|
||||
|
||||
apache2ctl configtest && systemctl reload apache2
|
||||
Reference in New Issue
Block a user