fix missing then in blacklist.lua, disable site search in redis.init(), remove counter from reverse-proxy/stream config and fix ui tests compose pull
This commit is contained in:
parent
c7d8b7dc18
commit
b3769b6e3f
|
@ -346,7 +346,7 @@ function _M:preread()
|
|||
logger.log(ngx.NOTICE, "BLACKLIST", "IP is in cached ignore blacklist (info: " .. cached_ignored_ip .. ")")
|
||||
elseif cached_ip and cached_ip ~= "ok" then
|
||||
return true, "IP is in blacklist cache (info = " .. cached_ip .. ")", true, utils.get_deny_status()
|
||||
elseif cached_ip
|
||||
elseif cached_ip then
|
||||
return true, "IP is in blacklist cache (not blacklisted)", false, nil
|
||||
end
|
||||
|
||||
|
|
|
@ -14,11 +14,11 @@ end
|
|||
|
||||
function _M:init()
|
||||
-- Check if init is needed
|
||||
local init_needed, err = utils.get_variable("USE_REDIS", "yes")
|
||||
if init_needed == nil then
|
||||
local use_redis, err = utils.get_variable("USE_REDIS", false)
|
||||
if use_redis == nil then
|
||||
return false, "can't check USE_REDIS variable : " .. err
|
||||
end
|
||||
if not init_needed then
|
||||
if use_redis ~= "yes" then
|
||||
return true, "redis not used"
|
||||
end
|
||||
-- TODO : check redis connectivity
|
||||
|
|
|
@ -5,7 +5,7 @@
|
|||
proxy_protocol on;
|
||||
{% endif +%}
|
||||
|
||||
set $backend{{ counter.value }} "{{ host }}";
|
||||
proxy_pass $backend{{ counter.value }};
|
||||
set $backend "{{ host }}";
|
||||
proxy_pass $backend;
|
||||
|
||||
{% endif %}
|
|
@ -8,7 +8,16 @@ sed -i "s@bunkerity/bunkerweb:.*@local/bunkerweb-tests:$MODE@" docker-compose.ym
|
|||
sed -i "s@bunkerity/bunkerweb:.*@local/scheduler-tests:$MODE@" docker-compose.yml
|
||||
|
||||
# Start stack
|
||||
docker-compose pull --ignore-pull-failures
|
||||
if [ $? -ne 0 ] ; then
|
||||
echo "❌ Pull failed"
|
||||
exit 1
|
||||
fi
|
||||
docker-compose up -d
|
||||
if [ $? -ne 0 ] ; then
|
||||
echo "❌ Up failed"
|
||||
exit 1
|
||||
fi
|
||||
i=0
|
||||
while [ $i -lt 120 ] ; do
|
||||
containers=("ui-bw-1" "ui-bw-scheduler-1" "ui-bw-ui-1" "ui-docker-proxy-1" "ui-app1-1")
|
||||
|
@ -33,6 +42,12 @@ if [ $i -ge 120 ] ; then
|
|||
fi
|
||||
|
||||
# Start tests
|
||||
docker-compose -f docker-compose.tests.yml build
|
||||
if [ $? -ne 0 ] ; then
|
||||
echo "❌ Build failed"
|
||||
exit 1
|
||||
fi
|
||||
docker-compose -f docker-compose.tests.yml up
|
||||
|
||||
# Exit
|
||||
exit $?
|
Loading…
Reference in New Issue