124 files changed
+2174
-951
No files matched your search
@@ -1,6 +1,6 @@
|
||||
module github.com/dokku/dokku/plugins/ports
|
||||
|
||||
go 1.23.0
|
||||
go 1.24.0
|
||||
|
||||
require (
|
||||
github.com/dokku/dokku/plugins/common v0.0.0-00010101000000-000000000000
|
||||
|
||||
@@ -25,8 +25,16 @@ func TriggerInstall() error {
|
||||
continue
|
||||
}
|
||||
|
||||
common.LogInfo1(fmt.Sprintf("Migrating DOKKU_PROXY_PORT_MAP to ports map property for %s", appName))
|
||||
portMapString := config.GetWithDefault(appName, "DOKKU_PROXY_PORT_MAP", "")
|
||||
results, _ := common.CallPlugnTrigger(common.PlugnTriggerInput{
|
||||
Trigger: "config-get",
|
||||
Args: []string{appName, "DOKKU_PROXY_PORT_MAP"},
|
||||
})
|
||||
portMapString := results.StdoutContents()
|
||||
if portMapString == "" {
|
||||
continue
|
||||
}
|
||||
|
||||
common.LogVerboseQuiet(fmt.Sprintf("Setting %s ports property 'map' to %v", appName, portMapString))
|
||||
portMaps, _ := parsePortMapString(portMapString)
|
||||
|
||||
propertyValue := []string{}
|
||||
@@ -38,7 +46,11 @@ func TriggerInstall() error {
|
||||
return err
|
||||
}
|
||||
|
||||
if err := config.UnsetMany(appName, []string{"DOKKU_PROXY_PORT_MAP"}, false); err != nil {
|
||||
_, err := common.CallPlugnTrigger(common.PlugnTriggerInput{
|
||||
Trigger: "config-unset",
|
||||
Args: []string{appName, "DOKKU_PROXY_PORT_MAP"},
|
||||
})
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user