Skip to content

Commit d9fea19

Browse files
committed
Fixed filename for defaults file.
1 parent 97c274e commit d9fea19

File tree

1 file changed

+5
-5
lines changed
  • docker/rootfs/etc/services.d/crowdsec_openresty_bouncer

1 file changed

+5
-5
lines changed

docker/rootfs/etc/services.d/crowdsec_openresty_bouncer/run

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -6,15 +6,15 @@ mkdir -p /data/crowdsec
66
if [ -f /data/crowdsec/crowdsec-openresty-bouncer.conf ]; then
77
echo "Patch crowdsec-openresty-bouncer.conf .."
88
sed "s/=.*//g" /data/crowdsec/crowdsec-openresty-bouncer.conf > /tmp/crowdsec.conf.raw
9-
sed "s/=.*//g" /defaults/crowdsec/config_example.conf > /tmp/config_example.conf.raw
10-
if grep -vf /tmp/crowdsec.conf.raw /tmp/config_example.conf.raw ; then
11-
grep -vf /tmp/crowdsec.conf.raw /tmp/config_example.conf.raw > /tmp/config_example.newvals
9+
sed "s/=.*//g" /defaults/crowdsec/crowdsec-openresty-bouncer.conf > /tmp/crowdsec-openresty-bouncer.conf.raw
10+
if grep -vf /tmp/crowdsec.conf.raw /tmp/crowdsec-openresty-bouncer.conf.raw ; then
11+
grep -vf /tmp/crowdsec.conf.raw /tmp/crowdsec-openresty-bouncer.conf.raw > /tmp/config.newvals
1212
cp /data/crowdsec/crowdsec-openresty-bouncer.conf /data/crowdsec/crowdsec-openresty-bouncer.conf.bak
13-
grep -f /tmp/config_example.newvals /defaults/crowdsec/config_example.conf >> /data/crowdsec/crowdsec-openresty-bouncer.conf
13+
grep -f /tmp/config.newvals /defaults/crowdsec/crowdsec-openresty-bouncer.conf >> /data/crowdsec/crowdsec-openresty-bouncer.conf
1414
fi
1515
else
1616
echo "Deploy new crowdsec-openresty-bouncer.conf .."
17-
cp /defaults/crowdsec/config_example.conf /data/crowdsec/crowdsec-openresty-bouncer.conf
17+
cp /defaults/crowdsec/crowdsec-openresty-bouncer.conf /data/crowdsec/crowdsec-openresty-bouncer.conf
1818
fi
1919
echo "Deploy Templates .."
2020
sed -i 's|/defaults/crowdsec/templates|/data/crowdsec/templates|' /data/crowdsec/crowdsec-openresty-bouncer.conf

0 commit comments

Comments
 (0)