mirror of https://github.com/kubernetes/kops.git
Added .service to hooks unit files
Recent versions of systemd (version 229 at least) included in Ubuntu 16.04 and Debian 9 require the systemd unit files to have a .service extension. Signed-off-by: Ali Rizwan <ari@hellofresh.com>
This commit is contained in:
parent
e5194cf08b
commit
c324b01b7a
|
@ -53,12 +53,12 @@ func (h *HookBuilder) Build(c *fi.ModelBuilderContext) error {
|
||||||
var name string
|
var name string
|
||||||
switch hook.Name {
|
switch hook.Name {
|
||||||
case "":
|
case "":
|
||||||
name = fmt.Sprintf("kops-hook-%d", j)
|
name = fmt.Sprintf("kops-hook-%d.service", j)
|
||||||
if isInstanceGroup {
|
if isInstanceGroup {
|
||||||
name = fmt.Sprintf("%s-ig", name)
|
name = fmt.Sprintf("%s-ig.service", name)
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
name = hook.Name
|
name = fmt.Sprintf("%s.service", hook.Name)
|
||||||
}
|
}
|
||||||
|
|
||||||
if _, found := hookNames[name]; found {
|
if _, found := hookNames[name]; found {
|
||||||
|
|
Loading…
Reference in New Issue