Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
slapos
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Joanne Hugé
slapos
Commits
9a30c7df
Commit
9a30c7df
authored
Jan 13, 2020
by
Łukasz Nowak
Browse files
Options
Browse Files
Download
Plain Diff
Update release candidate
parents
2e378733
d86b81f2
Changes
26
Hide whitespace changes
Inline
Side-by-side
Showing
26 changed files
with
250 additions
and
63 deletions
+250
-63
component/geoip2/buildout.cfg
component/geoip2/buildout.cfg
+4
-1
component/glib/buildout.cfg
component/glib/buildout.cfg
+10
-2
component/pkgconfig/buildout.cfg
component/pkgconfig/buildout.cfg
+3
-21
component/pylint/buildout.cfg
component/pylint/buildout.cfg
+13
-0
component/pylint/pylint-super_on_old_class.patch
component/pylint/pylint-super_on_old_class.patch
+48
-0
component/python-2.7/buildout.cfg
component/python-2.7/buildout.cfg
+10
-0
component/qemu-kvm/buildout.cfg
component/qemu-kvm/buildout.cfg
+2
-0
component/surykatka/buildout.hash.cfg
component/surykatka/buildout.hash.cfg
+1
-1
component/surykatka/requirements.txt
component/surykatka/requirements.txt
+1
-1
software/caddy-frontend/buildout.hash.cfg
software/caddy-frontend/buildout.hash.cfg
+1
-1
software/caddy-frontend/instance-apache-frontend.cfg.in
software/caddy-frontend/instance-apache-frontend.cfg.in
+21
-17
software/caddy-frontend/software.cfg
software/caddy-frontend/software.cfg
+0
-1
software/caddy-frontend/test/test.py
software/caddy-frontend/test/test.py
+4
-5
software/kvm/software.cfg
software/kvm/software.cfg
+0
-1
software/monitor/buildout.hash.cfg
software/monitor/buildout.hash.cfg
+2
-2
software/monitor/instance-edgetest-input-schema.json
software/monitor/instance-edgetest-input-schema.json
+6
-0
software/monitor/instance-edgetest-slave-input-schema.json
software/monitor/instance-edgetest-slave-input-schema.json
+6
-0
software/monitor/instance-monitor-edgebot.cfg.jinja2
software/monitor/instance-monitor-edgebot.cfg.jinja2
+4
-0
software/monitor/instance.cfg
software/monitor/instance.cfg
+1
-0
software/monitor/test/test.py
software/monitor/test/test.py
+88
-2
software/nextcloud/buildout.hash.cfg
software/nextcloud/buildout.hash.cfg
+1
-1
software/nextcloud/nextcloud-instance.cfg.in
software/nextcloud/nextcloud-instance.cfg.in
+17
-0
software/seleniumserver/software.cfg
software/seleniumserver/software.cfg
+0
-1
software/slaprunner/software.cfg
software/slaprunner/software.cfg
+0
-1
stack/erp5/buildout.cfg
stack/erp5/buildout.cfg
+4
-3
stack/slapos.cfg
stack/slapos.cfg
+3
-2
No files found.
component/geoip2/buildout.cfg
View file @
9a30c7df
...
@@ -17,5 +17,8 @@ rpath = ${:library-dirs}
...
@@ -17,5 +17,8 @@ rpath = ${:library-dirs}
[geolite2-country]
[geolite2-country]
recipe = slapos.recipe.build:download-unpacked
recipe = slapos.recipe.build:download-unpacked
url = http://geolite.maxmind.com/download/geoip/database/GeoLite2-Country.tar.gz#${:md5sum}
url = http://geolite.maxmind.com/download/geoip/database/GeoLite2-Country.tar.gz#${:md5sum}
md5sum =
ff7bcb609291b9f5ab14397ccc50625
4
md5sum =
dc6224c648350d90f344a0c5c3ca547
4
strip-top-level-dir = true
strip-top-level-dir = true
[versions]
geoip2 = 2.9.0
component/glib/buildout.cfg
View file @
9a30c7df
...
@@ -10,13 +10,21 @@ extends =
...
@@ -10,13 +10,21 @@ extends =
parts =
parts =
glib
glib
# --with-python=${buildout:executable} is simpler but we may end up with
# scripts whose shebang exceeds the kernel limit.
# And ${buildout:executable}/.. is not a valid $PATH part.
[glib-python]
recipe = collective.recipe.shelloutput
commands =
bin-directory = dirname ${buildout:executable}
[glib]
[glib]
recipe = slapos.recipe.cmmi
recipe = slapos.recipe.cmmi
shared = true
shared = true
url = https://ftp.gnome.org/pub/gnome/sources/glib/2.56/glib-2.56.4.tar.xz
url = https://ftp.gnome.org/pub/gnome/sources/glib/2.56/glib-2.56.4.tar.xz
md5sum = 17c3dca43d99a4882384f1a7b530b80b
md5sum = 17c3dca43d99a4882384f1a7b530b80b
configure-options =
configure-options =
--with-python=
${buildout:executable}
--with-python=
python
--disable-libmount
--disable-libmount
--disable-static
--disable-static
--disable-selinux
--disable-selinux
...
@@ -24,7 +32,7 @@ configure-options =
...
@@ -24,7 +32,7 @@ configure-options =
--disable-xattr
--disable-xattr
--disable-man
--disable-man
environment =
environment =
PATH=${gettext:location}/bin:${perl:location}/bin:${xz-utils:location}/bin:%(PATH)s
PATH=${g
lib-python:bin-directory}:${g
ettext:location}/bin:${perl:location}/bin:${xz-utils:location}/bin:%(PATH)s
CPPFLAGS=-I${gettext:location}/include -I${zlib:location}/include
CPPFLAGS=-I${gettext:location}/include -I${zlib:location}/include
LDFLAGS=-L${gettext:location}/lib -Wl,-rpath=${gettext:location}/lib -L${zlib:location}/lib -Wl,-rpath=${zlib:location}/lib
LDFLAGS=-L${gettext:location}/lib -Wl,-rpath=${gettext:location}/lib -L${zlib:location}/lib -Wl,-rpath=${zlib:location}/lib
LIBFFI_CFLAGS=-I${libffi:location}/include
LIBFFI_CFLAGS=-I${libffi:location}/include
...
...
component/pkgconfig/buildout.cfg
View file @
9a30c7df
...
@@ -4,30 +4,12 @@
...
@@ -4,30 +4,12 @@
[buildout]
[buildout]
parts =
parts =
pkgconfig
pkgconfig
extends =
../gettext/buildout.cfg
../glib/buildout.cfg
[pkg-config]
<= pkgconfig
[pkgconfig]
[pkgconfig]
recipe = slapos.recipe.cmmi
recipe = slapos.recipe.cmmi
shared = true
shared = true
url = https://pkgconfig.freedesktop.org/releases/pkg-config-0.29.tar.gz
url = https://pkgconfig.freedesktop.org/releases/pkg-config-0.29.2.tar.gz
md5sum = 77f27dce7ef88d0634d0d6f90e03a77f
md5sum = f6e931e319531b736fadc017f470e68a
location = @@LOCATION@@
# build pkg-config twice so that second configure can use pkg-config
# to compute GLIB_CFLAGS and GLIB_LIBS.
pre-configure =
./configure --prefix=${:location} --with-installed-glib && make
configure-options =
configure-options =
--with-in
stalled
-glib
--with-in
ternal
-glib
--disable-host-tool
--disable-host-tool
environment =
PATH=.:%(PATH)s
PKG_CONFIG_PATH=${glib:location}/lib/pkgconfig:${pcre:location}/lib/pkgconfig
CPPFLAGS=-I${glib:location}/include
LDFLAGS=-L${gettext:location}/lib -Wl,-rpath=${gettext:location}/lib -L${glib:location}/lib -Wl,-rpath=${glib:location}/lib
GLIB_CFLAGS=-I${glib:location}/include/glib-2.0 -I${glib:location}/lib/glib-2.0/include
GLIB_LIBS=-L${glib:location}/lib -lglib-2.0 -lintl
component/pylint/buildout.cfg
0 → 100644
View file @
9a30c7df
[buildout]
parts =
pylint
extends =
../patch/buildout.cfg
[pylint]
recipe = zc.recipe.egg:custom
egg = pylint
patches =
${:_profile_base_location_}/pylint-super_on_old_class.patch#cb0c3f8c091bf4980be395c917edc435
patch-options = -p1
patch-binary = ${patch:location}/bin/patch
component/pylint/pylint-super_on_old_class.patch
0 → 100644
View file @
9a30c7df
commit 6cf07b3483ec0d921296aefa8a28a8491f13786e
Author: Claudiu Popa <pcmanticore@gmail.com>
Date: Sun Dec 6 14:54:52 2015 +0200
Don't emit super-on-old-class on classes with unknown bases.
The change also removes the confidence handling for super-on-old-class,
which isn't used enough to merit its existence.
Closes issue #721.
--- a/pylint/checkers/newstyle.py 2019-12-25 13:51:01.611586402 +0900
+++ b/pylint/checkers/newstyle.py 2019-12-25 13:50:31.861542768 +0900
@@ -127,12 +127,9 @@
if isinstance(call, astroid.CallFunc) and \
isinstance(call.func, astroid.Name) and \
call.func.name == 'super':
- confidence = (INFERENCE if has_known_bases(klass)
- else INFERENCE_FAILURE)
- if not klass.newstyle:
+ if not klass.newstyle and has_known_bases(klass):
# super should not be used on an old style class
- self.add_message('super-on-old-class', node=node,
- confidence=confidence)
+ self.add_message('super-on-old-class', node=node)
else:
# super first arg should be the class
if not call.args and sys.version_info[0] == 3:
@@ -146,8 +143,7 @@
continue
if supcls is None:
- self.add_message('missing-super-argument', node=call,
- confidence=confidence)
+ self.add_message('missing-super-argument', node=call)
continue
if klass is not supcls:
@@ -163,8 +159,7 @@
if name is not None:
self.add_message('bad-super-call',
node=call,
- args=(name, ),
- confidence=confidence)
+ args=(name, ))
def register(linter):
component/python-2.7/buildout.cfg
View file @
9a30c7df
...
@@ -56,6 +56,16 @@ configure-options =
...
@@ -56,6 +56,16 @@ configure-options =
# Profiled build:
# Profiled build:
make-binary =
make-binary =
make-targets = make profile-opt && make install
make-targets = make profile-opt && make install
# Mangle shebang to use installed Python. This is not only a convenience:
# when building system packages (e.g. re6st-node using OBS), some OS like
# recent RedHat would otherwise mangle them, either failing ('python' is
# ambiguous and 'python2' is not supported anymore) or replacing with
# something that's really wrong (/usr/bin/python...).
post-install = cd '${:prefix}' &&
find -executable -type f -print0 |
xargs -0 grep -I -m 1 '' |
sed -n 's,:#! */usr/bin/env \+python2\?$,,p' |
xargs -d '\n' sed -i '1s,.*,#!${:executable},'
extra-ldflags =
extra-ldflags =
# the entry "-Wl,-rpath=${file:location}/lib" below is needed by python-magic,
# the entry "-Wl,-rpath=${file:location}/lib" below is needed by python-magic,
...
...
component/qemu-kvm/buildout.cfg
View file @
9a30c7df
...
@@ -10,6 +10,8 @@ extends =
...
@@ -10,6 +10,8 @@ extends =
../pkgconfig/buildout.cfg
../pkgconfig/buildout.cfg
../xorg/buildout.cfg
../xorg/buildout.cfg
../zlib/buildout.cfg
../zlib/buildout.cfg
../pcre/buildout.cfg
../glib/buildout.cfg
# XXX Change all reference to kvm section to qemu section, then
# XXX Change all reference to kvm section to qemu section, then
# use qemu as main name section.
# use qemu as main name section.
...
...
component/surykatka/buildout.hash.cfg
View file @
9a30c7df
...
@@ -14,4 +14,4 @@
...
@@ -14,4 +14,4 @@
# not need these here).
# not need these here).
[surykatka-requirements]
[surykatka-requirements]
_update_hash_filename_ = requirements.txt
_update_hash_filename_ = requirements.txt
md5sum =
897c9a296625b576817f2a1dc1801a90
md5sum =
2dfe4f8b8c5b6f5d3478b70e53c49201
component/surykatka/requirements.txt
View file @
9a30c7df
...
@@ -7,5 +7,5 @@ idna==2.8
...
@@ -7,5 +7,5 @@ idna==2.8
miniupnpc==2.0.2
miniupnpc==2.0.2
peewee==3.13.1
peewee==3.13.1
requests==2.22.0
requests==2.22.0
surykatka==0.
1.1
surykatka==0.
2.0
urllib3==1.25.7
urllib3==1.25.7
software/caddy-frontend/buildout.hash.cfg
View file @
9a30c7df
...
@@ -22,7 +22,7 @@ md5sum = c801b7f9f11f0965677c22e6bbe9281b
...
@@ -22,7 +22,7 @@ md5sum = c801b7f9f11f0965677c22e6bbe9281b
[template-apache-frontend]
[template-apache-frontend]
filename = instance-apache-frontend.cfg.in
filename = instance-apache-frontend.cfg.in
md5sum =
c6d78b2856d9d0ec63728e668e3395d8
md5sum =
378f6da53a02b2bfe7777a493fc95585
[template-caddy-replicate]
[template-caddy-replicate]
filename = instance-apache-replicate.cfg.in
filename = instance-apache-replicate.cfg.in
...
...
software/caddy-frontend/instance-apache-frontend.cfg.in
View file @
9a30c7df
...
@@ -320,32 +320,36 @@ extra-context =
...
@@ -320,32 +320,36 @@ extra-context =
# BBB: SlapOS Master non-zero knowledge END
# BBB: SlapOS Master non-zero knowledge END
[caddy-wrapper]
[caddy-wrapper]
recipe = slapos.cookbook:wrapper
recipe = slapos.recipe.template:jinja2
environment =
template = inline:
CADDYPATH=${directory:frontend_cluster}
#!/bin/sh
command-line = {{ parameter_dict['caddy'] }}
export CADDYPATH=${directory:frontend_cluster}
-conf ${dynamic-caddy-frontend-template:rendered}
ulimit -n $(ulimit -Hn)
-log ${caddy-configuration:error-log}
exec {{ parameter_dict['caddy'] }} \
-log-roll-mb 0
-conf ${dynamic-caddy-frontend-template:rendered} \
-log ${caddy-configuration:error-log} \
-log-roll-mb 0 \
{% if instance_parameter['configuration.global-disable-http2'].lower() in TRUE_VALUES %}
{% if instance_parameter['configuration.global-disable-http2'].lower() in TRUE_VALUES %}
-http2=false
-http2=false
\
{% else %}
{% else %}
-http2=true
-http2=true
\
{% endif %}
{% endif %}
{% if instance_parameter['configuration.enable-quic'].lower() in TRUE_VALUES %}
{% if instance_parameter['configuration.enable-quic'].lower() in TRUE_VALUES %}
-quic
-quic
\
{% endif %}
{% endif %}
-grace {{ instance_parameter['configuration.mpm-graceful-shutdown-timeout'] }}s
-grace {{ instance_parameter['configuration.mpm-graceful-shutdown-timeout'] }}s \
-disable-http-challenge
-disable-http-challenge \
-disable-tls-alpn-challenge
-disable-tls-alpn-challenge \
wrapper-path = ${directory:bin}/caddy-wrapper
"$@"
rendered = ${directory:bin}/caddy-wrapper
mode = 0755
[caddy-frontend]
[caddy-frontend]
recipe = slapos.cookbook:wrapper
recipe = slapos.cookbook:wrapper
command-line = ${caddy-wrapper:
wrapper-path
} -pidfile ${caddy-configuration:pid-file}
command-line = ${caddy-wrapper:
rendered
} -pidfile ${caddy-configuration:pid-file}
wrapper-path = ${directory:service}/frontend_caddy
wrapper-path = ${directory:service}/frontend_caddy
hash-existing-files = ${buildout:directory}/software_release/buildout.cfg
hash-existing-files = ${buildout:directory}/software_release/buildout.cfg
hash-files = ${caddy-wrapper:
wrapper-path
}
hash-files = ${caddy-wrapper:
rendered
}
[not-found-html]
[not-found-html]
recipe = slapos.cookbook:symbolic.link
recipe = slapos.cookbook:symbolic.link
...
@@ -594,7 +598,7 @@ rendered = ${directory:bin}/frontend-caddy-validate
...
@@ -594,7 +598,7 @@ rendered = ${directory:bin}/frontend-caddy-validate
mode = 0700
mode = 0700
last_state_file = ${directory:run}/caddy_configuration_last_state
last_state_file = ${directory:run}/caddy_configuration_last_state
extra-context =
extra-context =
key wrapper caddy-wrapper:
wrapper-path
key wrapper caddy-wrapper:
rendered
key caddy_configuration_state frontend-caddy-configuration-state-validate:rendered
key caddy_configuration_state frontend-caddy-configuration-state-validate:rendered
key last_state_file :last_state_file
key last_state_file :last_state_file
...
...
software/caddy-frontend/software.cfg
View file @
9a30c7df
...
@@ -27,4 +27,3 @@ smmap = 0.9.0
...
@@ -27,4 +27,3 @@ smmap = 0.9.0
numpy = 1.16.4
numpy = 1.16.4
websockify = 0.8.0
websockify = 0.8.0
collective.recipe.shelloutput = 0.1
software/caddy-frontend/test/test.py
View file @
9a30c7df
...
@@ -534,7 +534,7 @@ class SlaveHttpFrontendTestCase(SlapOSInstanceTestCase):
...
@@ -534,7 +534,7 @@ class SlaveHttpFrontendTestCase(SlapOSInstanceTestCase):
cls
.
startServerProcess
()
cls
.
startServerProcess
()
except
BaseException
:
except
BaseException
:
cls
.
logger
.
exception
(
"Error during setUpClass"
)
cls
.
logger
.
exception
(
"Error during setUpClass"
)
cls
.
_cleanup
()
cls
.
_cleanup
(
'setUpClass'
)
cls
.
setUp
=
lambda
self
:
self
.
fail
(
'Setup Class failed.'
)
cls
.
setUp
=
lambda
self
:
self
.
fail
(
'Setup Class failed.'
)
raise
raise
...
@@ -559,8 +559,7 @@ class SlaveHttpFrontendTestCase(SlapOSInstanceTestCase):
...
@@ -559,8 +559,7 @@ class SlaveHttpFrontendTestCase(SlapOSInstanceTestCase):
cls
.
waitForCaddy
()
cls
.
waitForCaddy
()
except
BaseException
:
except
BaseException
:
cls
.
logger
.
exception
(
"Error during setUpClass"
)
cls
.
logger
.
exception
(
"Error during setUpClass"
)
cls
.
_storeSnapshot
(
"{}.setUpClass"
.
format
(
cls
.
__name__
))
cls
.
_cleanup
(
'setUpClass'
)
cls
.
_cleanup
()
cls
.
setUp
=
lambda
self
:
self
.
fail
(
'Setup Class failed.'
)
cls
.
setUp
=
lambda
self
:
self
.
fail
(
'Setup Class failed.'
)
raise
raise
...
@@ -854,9 +853,9 @@ class SlaveHttpFrontendTestCase(SlapOSInstanceTestCase):
...
@@ -854,9 +853,9 @@ class SlaveHttpFrontendTestCase(SlapOSInstanceTestCase):
break
break
@classmethod
@classmethod
def _cleanup(cls):
def _cleanup(cls
, snapshot_name
):
cls.stopServerProcess()
cls.stopServerProcess()
super(SlaveHttpFrontendTestCase, cls)._cleanup()
super(SlaveHttpFrontendTestCase, cls)._cleanup(
snapshot_name
)
def patchRequests(self):
def patchRequests(self):
HTTPResponse = requests.packages.urllib3.response.HTTPResponse
HTTPResponse = requests.packages.urllib3.response.HTTPResponse
...
...
software/kvm/software.cfg
View file @
9a30c7df
...
@@ -196,7 +196,6 @@ context =
...
@@ -196,7 +196,6 @@ context =
websockify = 0.5.1
websockify = 0.5.1
collective.recipe.environment = 0.2.0
collective.recipe.environment = 0.2.0
collective.recipe.shelloutput = 0.1
gitdb = 0.6.4
gitdb = 0.6.4
pycurl = 7.43.0
pycurl = 7.43.0
slapos.recipe.template = 4.3
slapos.recipe.template = 4.3
...
...
software/monitor/buildout.hash.cfg
View file @
9a30c7df
...
@@ -14,7 +14,7 @@
...
@@ -14,7 +14,7 @@
# not need these here).
# not need these here).
[template]
[template]
filename = instance.cfg
filename = instance.cfg
md5sum =
cb814297f2f76dc8e08014a7d662439
f
md5sum =
d778b6f436ae6864819eb2ff2d12a86
f
[template-monitor]
[template-monitor]
_update_hash_filename_ = instance-monitor.cfg.jinja2
_update_hash_filename_ = instance-monitor.cfg.jinja2
...
@@ -30,7 +30,7 @@ md5sum = 9e237dbdda59e788202f0da194a57d41
...
@@ -30,7 +30,7 @@ md5sum = 9e237dbdda59e788202f0da194a57d41
[template-monitor-edgebot]
[template-monitor-edgebot]
_update_hash_filename_ = instance-monitor-edgebot.cfg.jinja2
_update_hash_filename_ = instance-monitor-edgebot.cfg.jinja2
md5sum =
cd4c5d2ecf8285ea8f0905ed1150d8a0
md5sum =
8786e4245db0d27dfa4815222d970e52
[network-bench-cfg]
[network-bench-cfg]
filename = network_bench.cfg.in
filename = network_bench.cfg.in
...
...
software/monitor/instance-edgetest-input-schema.json
View file @
9a30c7df
...
@@ -18,6 +18,12 @@
...
@@ -18,6 +18,12 @@
"title"
:
"Default space separated list of Frontend IPs to check"
,
"title"
:
"Default space separated list of Frontend IPs to check"
,
"description"
:
"Default list of Frontend IPs to check, if empty no constraint is used."
,
"description"
:
"Default list of Frontend IPs to check, if empty no constraint is used."
,
"type"
:
"string"
"type"
:
"string"
},
"check-certificate-expiration-days"
:
{
"default"
:
"15"
,
"title"
:
"Default certificate expiration days check"
,
"description"
:
"Default amount of days to consider certitifcate as being to-be-expired (default: 15)."
,
"type"
:
"string"
}
}
}
}
}
}
software/monitor/instance-edgetest-slave-input-schema.json
View file @
9a30c7df
...
@@ -17,6 +17,12 @@
...
@@ -17,6 +17,12 @@
"title"
:
"Space separated list of Frontend IPs to check"
,
"title"
:
"Space separated list of Frontend IPs to check"
,
"description"
:
"List of Frontend IPs to check, if empty no constraint is used (default: comes from master partition)."
,
"description"
:
"List of Frontend IPs to check, if empty no constraint is used (default: comes from master partition)."
,
"type"
:
"string"
"type"
:
"string"
},
"check-certificate-expiration-days"
:
{
"default"
:
"Master default"
,
"title"
:
"Certificate expiration days check"
,
"description"
:
"Default amount of days to consider certitifcate as being to-be-expired (default: comes from master partition)."
,
"type"
:
"string"
}
}
}
}
}
}
software/monitor/instance-monitor-edgebot.cfg.jinja2
View file @
9a30c7df
...
@@ -13,6 +13,9 @@
...
@@ -13,6 +13,9 @@
{%- if 'check-status-code' not in slave %}
{%- if 'check-status-code' not in slave %}
{%- do slave.__setitem__('check-status-code', CONFIGURATION['check-status-code']) %}
{%- do slave.__setitem__('check-status-code', CONFIGURATION['check-status-code']) %}
{%- endif %}
{%- endif %}
{%- if 'check-certificate-expiration-days' not in slave %}
{%- do slave.__setitem__('check-certificate-expiration-days', CONFIGURATION['check-certificate-expiration-days']) %}
{%- endif %}
{%- if 'check-frontend-ip' not in slave %}
{%- if 'check-frontend-ip' not in slave %}
{%- do slave.__setitem__('check-frontend-ip', CONFIGURATION['check-frontend-ip']) %}
{%- do slave.__setitem__('check-frontend-ip', CONFIGURATION['check-frontend-ip']) %}
{%- endif %}
{%- endif %}
...
@@ -33,6 +36,7 @@ name = {{ safe_name }}.py
...
@@ -33,6 +36,7 @@ name = {{ safe_name }}.py
config-report = http_query
config-report = http_query
config-url = {{ slave['url'] }}
config-url = {{ slave['url'] }}
config-status-code = {{ slave['check-status-code'] }}
config-status-code = {{ slave['check-status-code'] }}
config-certificate-expiration-days = {{ slave['check-certificate-expiration-days'] }}
config-ip-list = {{ slave['check-frontend-ip'] }}
config-ip-list = {{ slave['check-frontend-ip'] }}
config-json-file = ${surykatka-config:json}
config-json-file = ${surykatka-config:json}
{% endfor %}
{% endfor %}
...
...
software/monitor/instance.cfg
View file @
9a30c7df
...
@@ -78,6 +78,7 @@ cert = $${slap-connection:cert-file}
...
@@ -78,6 +78,7 @@ cert = $${slap-connection:cert-file}
configuration.check-status-code = 200
configuration.check-status-code = 200
configuration.nameserver =
configuration.nameserver =
configuration.check-frontend-ip =
configuration.check-frontend-ip =
configuration.check-certificate-expiration-days = 15
# use monitor-base-port to have monitor listening on each instance
# use monitor-base-port to have monitor listening on each instance
# on different port and also on different port than other services
# on different port and also on different port than other services
# it makes it possible to instantiate it correctly on signle IP, for
# it makes it possible to instantiate it correctly on signle IP, for
...
...
software/monitor/test/test.py
View file @
9a30c7df
...
@@ -29,6 +29,7 @@ import json
...
@@ -29,6 +29,7 @@ import json
import
os
import
os
import
re
import
re
import
requests
import
requests
import
subprocess
import
xml.etree.ElementTree
as
ET
import
xml.etree.ElementTree
as
ET
from
slapos.recipe.librecipe
import
generateHashFromFiles
from
slapos.recipe.librecipe
import
generateHashFromFiles
from
slapos.testing.testcase
import
makeModuleSetUpAndTestCaseClass
from
slapos.testing.testcase
import
makeModuleSetUpAndTestCaseClass
...
@@ -225,11 +226,13 @@ class EdgeSlaveMixin(MonitorTestMixin):
...
@@ -225,11 +226,13 @@ class EdgeSlaveMixin(MonitorTestMixin):
def
assertSurykatkaStatusJSON
(
self
):
def
assertSurykatkaStatusJSON
(
self
):
if
os
.
path
.
exists
(
self
.
surykatka_json
):
if
os
.
path
.
exists
(
self
.
surykatka_json
):
os
.
unlink
(
self
.
surykatka_json
)
os
.
unlink
(
self
.
surykatka_json
)
self
.
assertEqual
(
0
,
os
.
system
(
self
.
surykatka_status_json
))
env
=
os
.
environ
.
copy
()
env
.
pop
(
'PYTHONPATH'
,
None
)
subprocess
.
check_call
(
self
.
surykatka_status_json
,
shell
=
True
,
env
=
env
)
self
.
assertTrue
(
os
.
path
.
exists
(
self
.
surykatka_json
))
self
.
assertTrue
(
os
.
path
.
exists
(
self
.
surykatka_json
))
with
open
(
self
.
surykatka_json
)
as
fh
:
with
open
(
self
.
surykatka_json
)
as
fh
:
status_json
=
json
.
load
(
fh
)
status_json
=
json
.
load
(
fh
)
self
.
assert
True
(
'bot_status'
in
status_json
)
self
.
assert
In
(
'bot_status'
,
status_json
)
def
test
(
self
):
def
test
(
self
):
# Note: Those tests do not run surykatka and do not do real checks, as
# Note: Those tests do not run surykatka and do not do real checks, as
...
@@ -266,6 +269,9 @@ URL =
...
@@ -266,6 +269,9 @@ URL =
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-300-promise.py'
,
'http-query-backend-300-promise.py'
,
"'status-code': '300'"
)
"'status-code': '300'"
)
self
.
assertPromiseContent
(
'http-query-backend-300-promise.py'
,
"'certificate-expiration-days': '15'"
)
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-300-promise.py'
,
'http-query-backend-300-promise.py'
,
"'url': 'https://www.erp5.org/'"
)
"'url': 'https://www.erp5.org/'"
)
...
@@ -283,6 +289,9 @@ URL =
...
@@ -283,6 +289,9 @@ URL =
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
'http-query-backend-promise.py'
,
"'status-code': '200'"
)
"'status-code': '200'"
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'certificate-expiration-days': '15'"
)
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
'http-query-backend-promise.py'
,
"'url': 'https://www.erp5.com/'"
)
"'url': 'https://www.erp5.com/'"
)
...
@@ -331,6 +340,9 @@ URL =
...
@@ -331,6 +340,9 @@ URL =
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
'http-query-backend-promise.py'
,
"'status-code': '200'"
)
"'status-code': '200'"
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'certificate-expiration-days': '15'"
)
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
'http-query-backend-promise.py'
,
"'url': 'https://www.erp5.com/'"
)
"'url': 'https://www.erp5.com/'"
)
...
@@ -370,6 +382,9 @@ URL =
...
@@ -370,6 +382,9 @@ URL =
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-501-promise.py'
,
'http-query-backend-501-promise.py'
,
"'status-code': '501'"
)
"'status-code': '501'"
)
self
.
assertPromiseContent
(
'http-query-backend-501-promise.py'
,
"'certificate-expiration-days': '15'"
)
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-501-promise.py'
,
'http-query-backend-501-promise.py'
,
"'url': 'https://www.erp5.org/'"
)
"'url': 'https://www.erp5.org/'"
)
...
@@ -387,6 +402,9 @@ URL =
...
@@ -387,6 +402,9 @@ URL =
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
'http-query-backend-promise.py'
,
"'status-code': '500'"
)
"'status-code': '500'"
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'certificate-expiration-days': '15'"
)
self
.
assertPromiseContent
(
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
'http-query-backend-promise.py'
,
"'url': 'https://www.erp5.com/'"
)
"'url': 'https://www.erp5.com/'"
)
...
@@ -404,3 +422,71 @@ URL =
...
@@ -404,3 +422,71 @@ URL =
'backend-501'
,
'backend-501'
,
{
'url'
:
'https://www.erp5.org/'
,
'check-status-code'
:
'501'
},
{
'url'
:
'https://www.erp5.org/'
,
'check-status-code'
:
'501'
},
)
)
class
TestEdgeCheckCertificateExpirationDays
(
EdgeSlaveMixin
,
SlapOSInstanceTestCase
):
surykatka_ini
=
"""[SURYKATKA]
INTERVAL = 120
SQLITE = %(partition_path)s/srv/surykatka.db
URL =
https://www.erp5.com/
https://www.erp5.org/"""
@
classmethod
def
getInstanceParameterDict
(
cls
):
return
{
'check-certificate-expiration-days'
:
'10'
,
}
def
assertSurykatkaPromises
(
self
):
self
.
assertPromiseContent
(
'http-query-backend-20-promise.py'
,
"'ip-list': ''"
)
self
.
assertPromiseContent
(
'http-query-backend-20-promise.py'
,
"'report': 'http_query'"
)
self
.
assertPromiseContent
(
'http-query-backend-20-promise.py'
,
"'status-code': '200'"
)
self
.
assertPromiseContent
(
'http-query-backend-20-promise.py'
,
"'certificate-expiration-days': '20'"
)
self
.
assertPromiseContent
(
'http-query-backend-20-promise.py'
,
"'url': 'https://www.erp5.org/'"
)
self
.
assertPromiseContent
(
'http-query-backend-20-promise.py'
,
"'json-file': '%s'"
%
(
self
.
surykatka_json
,)
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'ip-list': ''"
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'report': 'http_query'"
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'status-code': '200'"
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'certificate-expiration-days': '10'"
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'url': 'https://www.erp5.com/'"
)
self
.
assertPromiseContent
(
'http-query-backend-promise.py'
,
"'json-file': '%s'"
%
(
self
.
surykatka_json
,)
)
def
requestEdgetestSlaves
(
self
):
self
.
requestEdgetestSlave
(
'backend'
,
{
'url'
:
'https://www.erp5.com/'
},
)
self
.
requestEdgetestSlave
(
'backend-20'
,
{
'url'
:
'https://www.erp5.org/'
,
'check-certificate-expiration-days'
:
'20'
},
)
software/nextcloud/buildout.hash.cfg
View file @
9a30c7df
...
@@ -26,4 +26,4 @@ md5sum = fbc5eacda192cb02c8d9861cb628fe6f
...
@@ -26,4 +26,4 @@ md5sum = fbc5eacda192cb02c8d9861cb628fe6f
[template-nextcloud-instance]
[template-nextcloud-instance]
filename = nextcloud-instance.cfg.in
filename = nextcloud-instance.cfg.in
md5sum =
426df55e81725cd7faa408d3cd93558e
md5sum =
28f9a64176e86360a3398742d5ad8470
software/nextcloud/nextcloud-instance.cfg.in
View file @
9a30c7df
...
@@ -96,6 +96,23 @@ depends =
...
@@ -96,6 +96,23 @@ depends =
${nextcloud-backup-cron:recipe}
${nextcloud-backup-cron:recipe}
${nextcloud-news-updater:recipe}
${nextcloud-news-updater:recipe}
${nextcloud-config-update:recipe}
${nextcloud-config-update:recipe}
${nextcloud-install-promise:name}
[nextcloud-install-promise]
<= monitor-promise-base
module = check_command_execute
name = check-nextcloud-install.py
config-command = ${nc-install-wrapper:output}
[nc-install-wrapper]
recipe = collective.recipe.template
input = inline:#!/bin/bash
if [ -f "${instance-parameter:nextcloud}/config/CAN_INSTALL" ]; then
echo "Nextcloud is not installed.";
exit 1;
fi
output = ${directory:bin}/check-nc-install
mode = 744
[nextcloud-apache-httpd]
[nextcloud-apache-httpd]
recipe = slapos.recipe.template:jinja2
recipe = slapos.recipe.template:jinja2
...
...
software/seleniumserver/software.cfg
View file @
9a30c7df
...
@@ -46,5 +46,4 @@ output = ${buildout:directory}/template-selenium.cfg
...
@@ -46,5 +46,4 @@ output = ${buildout:directory}/template-selenium.cfg
[versions]
[versions]
plone.recipe.command = 1.1
plone.recipe.command = 1.1
collective.recipe.shelloutput = 0.1
slapos.recipe.template = 4.3
slapos.recipe.template = 4.3
software/slaprunner/software.cfg
View file @
9a30c7df
...
@@ -171,7 +171,6 @@ gunicorn = 19.7.1
...
@@ -171,7 +171,6 @@ gunicorn = 19.7.1
prettytable = 0.7.2
prettytable = 0.7.2
pycurl = 7.43.0
pycurl = 7.43.0
slapos.recipe.template = 4.3
slapos.recipe.template = 4.3
collective.recipe.shelloutput = 0.1
collective.recipe.environment = 0.2.0
collective.recipe.environment = 0.2.0
smmap = 0.9.0
smmap = 0.9.0
lockfile = 0.12.2
lockfile = 0.12.2
...
...
stack/erp5/buildout.cfg
View file @
9a30c7df
...
@@ -61,6 +61,7 @@ extends =
...
@@ -61,6 +61,7 @@ extends =
../../component/postfix/buildout.cfg
../../component/postfix/buildout.cfg
../../component/zbarlight/buildout.cfg
../../component/zbarlight/buildout.cfg
../../component/perl/buildout.cfg
../../component/perl/buildout.cfg
../../component/pylint/buildout.cfg
../../stack/caucase/buildout.cfg
../../stack/caucase/buildout.cfg
../../software/jupyter/software.cfg
../../software/jupyter/software.cfg
../../software/neoppod/software-common.cfg
../../software/neoppod/software-common.cfg
...
@@ -516,7 +517,7 @@ eggs = ${neoppod:eggs}
...
@@ -516,7 +517,7 @@ eggs = ${neoppod:eggs}
decorator
decorator
networkx
networkx
# Needed for checking ZODB Components source code
# Needed for checking ZODB Components source code
pylint
${pylint:egg}
jedi
jedi
yapf
yapf
typing
typing
...
@@ -653,6 +654,8 @@ ocropy = 1.0+SlapOSPatched001
...
@@ -653,6 +654,8 @@ ocropy = 1.0+SlapOSPatched001
pysvn = 1.7.10+SlapOSPatched002
pysvn = 1.7.10+SlapOSPatched002
python-ldap = 2.4.32+SlapOSPatched001
python-ldap = 2.4.32+SlapOSPatched001
python-magic = 0.4.12+SlapOSPatched001
python-magic = 0.4.12+SlapOSPatched001
## https://lab.nexedi.com/nexedi/slapos/merge_requests/648
pylint = 1.4.4
# use newer version than specified in ZTK
# use newer version than specified in ZTK
PasteDeploy = 1.5.2
PasteDeploy = 1.5.2
...
@@ -733,8 +736,6 @@ pycountry = 17.1.8
...
@@ -733,8 +736,6 @@ pycountry = 17.1.8
pycrypto = 2.6.1
pycrypto = 2.6.1
pycurl = 7.43.0
pycurl = 7.43.0
pyflakes = 1.5.0
pyflakes = 1.5.0
# pylint 1.5.1 breaks testDynamicClassGeneration
pylint = 1.4.4
python-memcached = 1.58
python-memcached = 1.58
pytracemalloc = 1.2
pytracemalloc = 1.2
qrcode = 5.3
qrcode = 5.3
...
...
stack/slapos.cfg
View file @
9a30c7df
...
@@ -117,6 +117,7 @@ cffi = 1.9.1
...
@@ -117,6 +117,7 @@ cffi = 1.9.1
click = 6.7
click = 6.7
cliff = 2.4.0
cliff = 2.4.0
cmd2 = 0.7.0
cmd2 = 0.7.0
collective.recipe.shelloutput = 0.1
collective.recipe.template = 2.0
collective.recipe.template = 2.0
cryptography = 2.3.1
cryptography = 2.3.1
decorator = 4.0.11
decorator = 4.0.11
...
@@ -137,14 +138,14 @@ pytz = 2016.10
...
@@ -137,14 +138,14 @@ pytz = 2016.10
requests = 2.13.0
requests = 2.13.0
six = 1.12.0
six = 1.12.0
slapos.cookbook = 1.0.123
slapos.cookbook = 1.0.123
slapos.core = 1.5.
5
slapos.core = 1.5.
6
slapos.extension.strip = 0.4
slapos.extension.strip = 0.4
slapos.extension.shared = 1.0
slapos.extension.shared = 1.0
slapos.libnetworkcache = 0.20
slapos.libnetworkcache = 0.20
slapos.rebootstrap = 4.2
slapos.rebootstrap = 4.2
slapos.recipe.build = 0.42
slapos.recipe.build = 0.42
slapos.recipe.cmmi = 0.12
slapos.recipe.cmmi = 0.12
slapos.toolbox = 0.10
1
slapos.toolbox = 0.10
4
stevedore = 1.21.0
stevedore = 1.21.0
subprocess32 = 3.5.3
subprocess32 = 3.5.3
unicodecsv = 0.14.1
unicodecsv = 0.14.1
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment