mirror of
https://github.com/m1k1o/neko-rooms.git
synced 2026-11-03 07:01:35 -06:00
add hostname & dns to docker-compose exporter.
This commit is contained in:
@@ -177,6 +177,16 @@ func (manager *RoomManagerCtx) ExportAsDockerCompose() ([]byte, error) {
|
||||
}
|
||||
}
|
||||
|
||||
// hostname
|
||||
if containerJson.Config.Hostname != containerName {
|
||||
service["hostname"] = containerJson.Config.Hostname
|
||||
}
|
||||
|
||||
// dns
|
||||
if len(containerJson.HostConfig.DNS) > 0 {
|
||||
service["dns"] = containerJson.HostConfig.DNS
|
||||
}
|
||||
|
||||
// ports
|
||||
ports := []string{}
|
||||
for port, host := range containerJson.HostConfig.PortBindings {
|
||||
|
||||
Reference in New Issue
Block a user