Use rm -rf in remove-old-socket (#409)

Use rm -rf in remove-old-socket (#409)

In some cases, the leftover socket is actually a directory.

From ceffc4433e1bd6fcbd101f2427e17232fc99ab14 Mon Sep 17 00:00:00 2001
From: Vincent <31770422+khannurien@users.noreply.github.com>
Date: Fri, 28 Sep 2018 11:41:18 +0200
Subject: [PATCH] Use rm -rf in remove-old-socket (#409)

In some cases, the leftover socket is actually a directory.

diff --git a/templates/web.socketed.template.yml b/templates/web.socketed.template.yml
index 2addf49..ff4f87a 100644
--- a/templates/web.socketed.template.yml
+++ b/templates/web.socketed.template.yml
@@ -10,7 +10,7 @@ run:
      chmod: "+x"
      contents: |
         #!/bin/bash
-        rm -f /shared/nginx.http*.sock
+        rm -rf /shared/nginx.http*.sock
   - replace:
      filename: "/etc/nginx/conf.d/discourse.conf"
      from: /listen 80;/

GitHub

1 Like