Commit a8eb76e6 authored by mh's avatar mh
Browse files

make it possible to map paths to different container ports

parent a7671465
......@@ -146,7 +146,14 @@ define webhosting::common(
$configuration['containers'].each |$con_name,$vals| {
$hosting_run_flags = pick($vals['run_flags'],{})
$con_values = ($vals - 'run_flags') + {
$publish = pick($vals['publish'],{})
$publish_socket = pick($vals['publish_socket'],{})
$publish_options = {
'dir' => "/var/www/vhosts/${name}/tmp/run",
'security-opt-label-type' => 'socat_httpd_sidecar',
}
$publis_socket_2 = Hash($publish.map |$e| { [$e[1], $publish_options] })
$con_values = ($vals - ['run_flags' - 'publish' - 'publish_socket']) + {
ensure => $ensure,
user => $real_uid_name,
uid => $real_uid,
......@@ -157,6 +164,7 @@ define webhosting::common(
logpath => "${vhost_path}/logs",
run_flags => $default_run_flags + $hosting_run_flags,
tag => "user_${real_uid_name}",
publish_socket => $publis_socket_2 + $publish_socket,
}
podman::container{
"${name}-${con_name}":
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment