diff --git a/api/module.go b/api/module.go index 643a624..7c223e6 100644 --- a/api/module.go +++ b/api/module.go @@ -54,8 +54,14 @@ func (m ModuleController) DeployModule(c *gin.Context) { cmd = append(cmd, branch) } + module := data.ModuleName + overrideModule := c.Query("module_name") + if overrideModule != "" { + module = overrideModule + } + // Append module name and r10k configuration to the cmd string slice - cmd = append(cmd, data.ModuleName) + cmd = append(cmd, module) cmd = append(cmd, fmt.Sprintf("--config=%s", h.GetR10kConfig())) // Set additional optional r10k flags if they are set