From 615db1413145dad0a50790a1572f04fedb110f7d Mon Sep 17 00:00:00 2001 From: Dennis Banga Date: Fri, 22 Dec 2023 00:30:22 +0300 Subject: [PATCH 1/2] fix indentation error hapi.yaml --- packaging/ansible/ubuntu/hapi.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/packaging/ansible/ubuntu/hapi.yaml b/packaging/ansible/ubuntu/hapi.yaml index a4077de9..a6aef830 100644 --- a/packaging/ansible/ubuntu/hapi.yaml +++ b/packaging/ansible/ubuntu/hapi.yaml @@ -7,7 +7,7 @@ tasks: - name: Add the OS specific variables - include_vars: + include_vars: file: index.yaml - name: hapi folder exists From a1552f39339c3577330c71a343d9bae67f133731 Mon Sep 17 00:00:00 2001 From: Dennis Banga Date: Fri, 22 Dec 2023 01:20:19 +0300 Subject: [PATCH 2/2] Extract stdout from node_path- gofr.service.j2 gets the stdout of the `which node` --- packaging/ansible/ubuntu/templates/gofr.service.j2 | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packaging/ansible/ubuntu/templates/gofr.service.j2 b/packaging/ansible/ubuntu/templates/gofr.service.j2 index fb8fa220..7756075c 100644 --- a/packaging/ansible/ubuntu/templates/gofr.service.j2 +++ b/packaging/ansible/ubuntu/templates/gofr.service.j2 @@ -6,9 +6,9 @@ After=network.target [Service] Type=simple WorkingDirectory=/var/lib/gofr/gofr-backend -ExecStart={{node_path}} /var/lib/gofr/gofr-backend/{{site}}/bin/www +ExecStart={{node_path.stdout}} /var/lib/gofr/gofr-backend/{{site}}/bin/www Restart=always Environment=NODE_ENV=production [Install] -WantedBy=multi-user.target \ No newline at end of file +WantedBy=multi-user.target