File tree Expand file tree Collapse file tree 1 file changed +5
-5
lines changed
docker/rootfs/etc/services.d/crowdsec_openresty_bouncer Expand file tree Collapse file tree 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change @@ -6,15 +6,15 @@ mkdir -p /data/crowdsec
6
6
if [ -f /data/crowdsec/crowdsec-openresty-bouncer.conf ]; then
7
7
echo "Patch crowdsec-openresty-bouncer.conf .."
8
8
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
12
12
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
14
14
fi
15
15
else
16
16
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
18
18
fi
19
19
echo "Deploy Templates .."
20
20
sed -i 's|/defaults/crowdsec/templates|/data/crowdsec/templates|' /data/crowdsec/crowdsec-openresty-bouncer.conf
You can’t perform that action at this time.
0 commit comments