Bob Mottram 7 vuotta sitten
vanhempi
commit
aa81bb930e
1 muutettua tiedostoa jossa 1 lisäystä ja 1 poistoa
  1. 1
    1
      src/freedombone-app-tahoelafs

+ 1
- 1
src/freedombone-app-tahoelafs Näytä tiedosto

600
     if [ ! -f /etc/nginx/.htpasswd-tahoelafs ]; then
600
     if [ ! -f /etc/nginx/.htpasswd-tahoelafs ]; then
601
         touch /etc/nginx/.htpasswd-tahoelafs
601
         touch /etc/nginx/.htpasswd-tahoelafs
602
     fi
602
     fi
603
-    if grep "${MY_USERNAME}:" /etc/nginx/.htpasswd-tahoelafs; then
603
+    if grep -q "${MY_USERNAME}:" /etc/nginx/.htpasswd-tahoelafs; then
604
         sed -i '/${MY_USERNAME}:/d' /etc/nginx/.htpasswd-tahoelafs
604
         sed -i '/${MY_USERNAME}:/d' /etc/nginx/.htpasswd-tahoelafs
605
     fi
605
     fi
606
     echo "${TAHOELAFS_ADMIN_PASSWORD}" | htpasswd -i -s /etc/nginx/.htpasswd-tahoelafs ${MY_USERNAME}
606
     echo "${TAHOELAFS_ADMIN_PASSWORD}" | htpasswd -i -s /etc/nginx/.htpasswd-tahoelafs ${MY_USERNAME}