From f76432f60a17bc32f1606372696d1627a9947d8e Mon Sep 17 00:00:00 2001 From: Alistair Hey Date: Sat, 28 Dec 2019 17:50:37 +0000 Subject: [PATCH] Add use of template to Install command The template name wasnt used, so the command gave an error saying that no template was used. Signed-off-by: Alistair Hey --- .gitignore | 1 + pkg/systemd/systemd.go | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index e18614b..6716816 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ /faasd hosts /resolv.conf +.idea/ diff --git a/pkg/systemd/systemd.go b/pkg/systemd/systemd.go index 9931945..373f583 100644 --- a/pkg/systemd/systemd.go +++ b/pkg/systemd/systemd.go @@ -66,7 +66,7 @@ func DaemonReload() error { func InstallUnit(name string) error { tmplName := "./hack/" + name + ".service" - tmpl, err := template.ParseFiles() + tmpl, err := template.ParseFiles(tmplName) if err != nil { return fmt.Errorf("error loading template %s, error %s", tmplName, err)