Commit 3d66d0dd authored by Jérome Perrin's avatar Jérome Perrin

Update Release Candidate

parents 83191535 1ea3bcae
......@@ -125,4 +125,3 @@ environment =
recipe = slapos.recipe.build:download
shared = true
url = ${:_profile_base_location_}/${:filename}
mode = 640
......@@ -18,7 +18,6 @@ strip-top-level-dir = true
[template-bazel-crosstool]
recipe = slapos.recipe.template:jinja2
location = ${buildout:parts-directory}/${:_buildout_section_name_}
mode = 640
filename = bazel_tools_cpp_CROSSTOOL
template = ${:_profile_base_location_}/${:filename}.in
rendered = ${:location}/${:filename}
......@@ -29,7 +28,6 @@ context =
[template-bazel-src-main-cpp-build]
recipe = slapos.recipe.template:jinja2
location = ${buildout:parts-directory}/${:_buildout_section_name_}
mode = 640
filename = bazel_src_main_cpp_BUILD
template = ${:_profile_base_location_}/${:filename}.in
rendered = ${:location}/${:filename}
......
......@@ -33,4 +33,3 @@ environment =
recipe = slapos.recipe.template
url = ${:_profile_base_location_}/${:filename}
output = ${buildout:parts-directory}/${:_buildout_section_name_}
mode = 640
......@@ -109,7 +109,6 @@ environment-extra =
recipe = slapos.recipe.template:jinja2
exe = ${buildout:bin-directory}/go
rendered= ${:exe}
mode = 755
template= inline:
#!/bin/sh -e
. ${gowork:env.sh}
......
......@@ -34,11 +34,10 @@ install =
[helloweb-go]
# we already have gowork/bin/helloweb with helloweb Go build.
# Add bin/helloweb-go that runs go version of helloweb without any environment preset needed.
recipe = collective.recipe.template
output = ${buildout:bin-directory}/${:_buildout_section_name_}
mode = 0755
input = inline:
#!/bin/sh
recipe = slapos.recipe.template:jinja2
rendered = ${buildout:bin-directory}/${:_buildout_section_name_}
template =
inline:#!/bin/sh -e
. ${gowork:env.sh}
exec helloweb "$@"
......@@ -93,15 +92,14 @@ path = ${helloweb:location}/ruby/
configure-command = :
make-binary =
make-targets= cd ${:path} && ${bundler:bundle} install
make-targets= ${bundler:bundle} install
[helloweb-ruby]
# NOTE slapos.cookbook:wrapper also works, but currently _only_ in instance
recipe = collective.recipe.template
output = ${buildout:bin-directory}/${:_buildout_section_name_}
mode = 0755
input = inline:
#!/bin/sh
recipe = slapos.recipe.template:jinja2
rendered = ${buildout:bin-directory}/${:_buildout_section_name_}
template =
inline:#!/bin/sh -e
export BUNDLE_GEMFILE=${helloweb-ruby-bundle:path}/Gemfile
exec ${bundler:bundle} exec sh -c 'helloweb.rb "$@"' ${:_buildout_section_name_} "$@"
......@@ -23,7 +23,6 @@ python_executable = ${buildout:bin-directory}/${:interpreter}
recipe = slapos.recipe.build:download
url = ${:_profile_base_location_}/${:filename}
download-only = true
mode = 0644
[jupyter-notebook-config]
<= download-file-base
......@@ -44,7 +43,6 @@ mode = 0644
recipe = slapos.recipe.template:jinja2
template = ${:_profile_base_location_}/${:filename}
rendered = ${buildout:directory}/template.cfg
mode = 0644
context =
key bin_directory buildout:bin-directory
key develop_eggs_directory buildout:develop-eggs-directory
......
......@@ -15,7 +15,7 @@
[instance-jupyter-notebook]
filename = instance.cfg.in
md5sum = 1d5fe6cc4e48672ae7be1c223794a932
md5sum = 357f28614a13cdbf00a29a83cbfd2642
[jupyter-notebook-config]
filename = jupyter_notebook_config.py.jinja
......
......@@ -37,10 +37,6 @@ key_file = ${generate-certificate:key_file}
logfile = ${directory:log}/jupyter_notebook.log
notebook_dir = ${directory:notebook_dir}
[dynamic-jinja2-template-base]
recipe = slapos.recipe.template:jinja2
mode = 0644
[generate-certificate]
; TODO: there is a slapos recipe to generate certificates. Use it instead
recipe = plone.recipe.command
......@@ -76,10 +72,9 @@ environment =
LANG=C.UTF-8
[jupyter-notebook-config]
<= dynamic-jinja2-template-base
recipe = slapos.recipe.template:jinja2
template = {{ jupyter_config_location }}/{{ jupyter_config_filename }}
rendered = ${directory:jupyter_config_dir}/jupyter_notebook_config.py
mode = 0744
context =
raw config_cfg ${buildout:directory}/knowledge0.cfg
......@@ -134,7 +129,7 @@ link-binary = {{ erp5_kernel_location }}/{{ erp5_kernel_filename }}
target-directory = ${directory:erp5_kernel_dir}
[kernel-json]
<= dynamic-jinja2-template-base
recipe = slapos.recipe.template:jinja2
template = {{ kernel_json_location }}/{{ kernel_json_filename }}
rendered = ${directory:erp5_kernel_dir}/kernel.json
# Use python2.7 executable bin file for kernel config
......
......@@ -13,7 +13,6 @@ filename = lapack-${:version}.tgz
url = http://www.netlib.org/lapack/${:filename}
md5sum = b1d3e3e425b2e44a06760ff173104bdf
download-only = true
mode = 0644
[libatlas]
recipe = slapos.recipe.cmmi
......
......@@ -14,7 +14,6 @@ recipe = slapos.recipe.template:jinja2
location = ${buildout:parts-directory}/${:_buildout_section_name_}
template = ${:_profile_base_location_}/${:filename}
rendered = ${matplotlibrc:location}/matplotlibrc
mode = 0644
backend = agg
context =
key backend matplotlibrc:backend
......
......@@ -124,6 +124,5 @@ template = inline:
exec ${perl:location}/bin/perl \
{% for item in inc -%}{% if item %} -I "{{ item }}" \
{% endif %}{% endfor %} "$@"
mode = 0755
rendered = ${buildout:bin-directory}/${:_buildout_section_name_}
perl-bin = ${:rendered}
# http://www.proftpd.org/ - Highly configurable GPL-licensed FTP server software
#
# Because it uses collective.recipe.environment this components needs slapos.core >= 1.4.7
# ( grid: do not hide `$USER` when running buildout )
#
[buildout]
extends =
../openssl/buildout.cfg
......@@ -15,11 +12,12 @@ extends =
../zstd/buildout.cfg
# proftpd server
[proftpd-environment]
recipe = collective.recipe.environment
[proftpd-grp]
recipe = collective.recipe.grp
[proftpd-info]
recipe = slapos.recipe.build
init =
import grp, os, pwd
options['USER'] = pwd.getpwuid(os.getuid())[0]
options['GROUP'] = grp.getgrgid(os.getgid())[0]
[proftpd]
recipe = slapos.recipe.cmmi
......@@ -36,12 +34,16 @@ environment =
CFLAGS=-DPR_RUN_DIR=\"/proc/self/cwd/var\"
CPPFLAGS=-I${zlib:location}/include -I${openssl:location}/include
LDFLAGS=-L${zlib:location}/lib -Wl,-rpath=${zlib:location}/lib -L${openssl:location}/lib -Wl,-rpath=${openssl:location}/lib
install_user=${proftpd-environment:USER}
install_group=${proftpd-grp:GROUP}
install_user=${proftpd-info:USER}
install_group=${proftpd-info:GROUP}
patch-binary = ${patch:location}/bin/patch
patch-options = -p1
patches =
${:_profile_base_location_}/0001-mod_rlimit-don-t-change-PR_SET_DUMPABLE-flag.patch#6e58a7a429ff96a51812dc9835e4c227
post-install =
sed -i '1c\
#!${perl:location}/bin/perl
' %(prefix)s/bin/ftpasswd
# mod_auth_web: a proftpd module to authenticate users against an HTTP service
[proftpd-mod_auth_web-repository]
......@@ -63,16 +65,6 @@ command =
${proftpd-mod_auth_web-repository:location}/mod_auth_web.c
location=${proftpd:location}/libexec/mod_auth_web.so
# ftpasswd: a perl script to manage a proftpd AuthUserFile
[ftpasswd]
recipe = slapos.recipe.build:download
url = https://raw.githubusercontent.com/proftpd/proftpd/v1.3.6/contrib/ftpasswd
md5sum = 4a47df2cab86d8de7077a445bb416f31
download-only = true
mode = 0755
[proftpd-output]
# Shared binary location to ease migration
recipe = plone.recipe.command
......@@ -82,8 +74,7 @@ command = ${coreutils-output:test} -x ${:proftpd} -a -x ${:ftpasswd}
modules-deps =
${proftpd-mod_auth_web:recipe}
perl = ${perl:location}/bin/perl
ftpasswd = ${ftpasswd:target}
ftpasswd = ${proftpd:location}/bin/ftpasswd
proftpd = ${proftpd:location}/sbin/proftpd
prxs = ${proftpd:location}/bin/prxs
ftpdctl = ${proftpd:location}/bin/ftpdctl
......@@ -3,8 +3,9 @@ parts = pure-ftpd
[pure-ftpd]
recipe = slapos.recipe.cmmi
url = https://download.pureftpd.org/pub/pure-ftpd/releases/pure-ftpd-1.0.49.tar.bz2
md5sum = b7025f469711d88bd84a3518f67c1470
url = https://github.com/jedisct1/pure-ftpd/releases/download/${:version}/pure-ftpd-${:version}.tar.bz2
version = 1.0.50
md5sum = f55af39fc85edceba4b02ee4fa116d00
# See https://download.pureftpd.org/pub/pure-ftpd/doc/README for more configurations
# We need the trick about UPLOAD_PIPE_FILE and UPLOAD_PIPE_LOCK so that the files are created inside the $CWD/var/run
......
......@@ -28,7 +28,7 @@ from setuptools import setup, find_packages
import glob
import os
version = '1.0.217'
version = '1.0.218'
name = 'slapos.cookbook'
long_description = open("README.rst").read()
......
......@@ -147,7 +147,7 @@ class Recipe(GenericBaseRecipe):
with open(postgres_conf, 'w') as cfg:
cfg.write(textwrap.dedent("""\
listen_addresses = '%s'
port = %s
%s
logging_collector = on
log_rotation_size = 50MB
max_connections = 100
......@@ -163,7 +163,7 @@ class Recipe(GenericBaseRecipe):
unix_socket_permissions = 0700
""" % (
','.join(set(ipv4).union(ipv6)),
self.options['port'],
'port = %s' % self.options['port'] if self.options['port'] else '',
pgdata,
)))
......
import os
import shutil
import tempfile
import textwrap
import time
import unittest
......@@ -54,7 +53,7 @@ class PostgresTest(unittest.TestCase):
self.addCleanup(server_process.terminate)
# wait for server to accept connections
for i in range(60):
for i in range(10):
time.sleep(i)
try:
psycopg2.connect(self.buildout['postgres']['url']).close()
......@@ -114,3 +113,7 @@ class PostgresTest(unittest.TestCase):
class PostgresTestNonStandardPort(PostgresTest):
port = 5433
class PostgresTestEmptyPort(PostgresTest):
port = ''
......@@ -19,7 +19,7 @@ md5sum = de37ec3d4adb0be4c67bcc7397f27c91
[instance-jupyter]
filename = instance-jupyter.cfg.in
md5sum = 95e3da48abdd257fb9d5dbdf14ea87b9
md5sum = 1136bb108aa8d703e0ecf2005b4a1f28
[jupyter-notebook-config]
filename = jupyter_notebook_config.py.jinja
......
......@@ -55,10 +55,6 @@ frontend-additional-instance-name = Jupyter Frontend Additional
{{ k }} = {{ v }}
{% endfor -%}
[dynamic-jinja2-template-base]
recipe = slapos.recipe.template:jinja2
mode = 0644
[generate-certificate]
; TODO: there is a slapos recipe to generate certificates. Use it instead
recipe = plone.recipe.command
......@@ -98,10 +94,9 @@ recipe = slapos.cookbook:generate.password
bytes = 10
[jupyter-notebook-config]
<= dynamic-jinja2-template-base
recipe = slapos.recipe.template:jinja2
template = {{ jupyter_config_location }}/{{ jupyter_config_filename }}
rendered = ${directory:jupyter_config_dir}/jupyter_notebook_config.py
mode = 0744
context =
key password jupyter-password:passwd
raw gcc_location {{ gcc_location }}
......@@ -192,7 +187,7 @@ link-binary = {{ erp5_kernel_location }}/{{ erp5_kernel_filename }}
target-directory = ${directory:erp5_kernel_dir}
[kernel-json]
<= dynamic-jinja2-template-base
recipe = slapos.recipe.template:jinja2
template = {{ kernel_json_location }}/{{ kernel_json_filename }}
rendered = ${directory:erp5_kernel_dir}/kernel.json
# Use python2.7 executable bin file for kernel config
......
......@@ -171,8 +171,6 @@ mode = 640
[versions]
websockify = 0.9.0
collective.recipe.environment = 0.2.0
gitdb = 0.6.4
pycurl = 7.43.0
smmap = 0.9.0
......@@ -15,11 +15,11 @@
[instance-profile]
filename = instance.cfg.in
md5sum = efb4238229681447aa7fe73898dffad4
md5sum = b62dd8dd89ef6627ebac20987a89a069
[instance-default]
filename = instance-default.cfg.in
md5sum = 4df64032e14c19363ad3dfe9aecf8e0c
md5sum = 16d592805c6c1756e54924242148ba85
[proftpd-config-file]
filename = proftpd-config-file.cfg.in
......
......@@ -102,7 +102,7 @@ config-port = ${proftpd:sftp-port}
recipe = slapos.cookbook:wrapper
wrapper-path =${buildout:bin-directory}/${:_buildout_section_name_}
command-line =
{{ perl_bin }} {{ ftpasswd_bin }} --passwd --home=${proftpd:data-dir} --shell=/bin/false --uid=${proftpd-userinfo:pw-uid} --gid=${proftpd-userinfo:gr-gid} --file ${auth-user-file:output}
{{ ftpasswd_bin }} --passwd --home=${proftpd:data-dir} --shell=/bin/false --uid=${proftpd-userinfo:pw-uid} --gid=${proftpd-userinfo:gr-gid} --file ${auth-user-file:output}
[auth-user-file]
recipe = plone.recipe.command
......
......@@ -24,7 +24,6 @@ context =
raw ftpasswd_bin {{ ftpasswd_bin }}
raw ftpdctl_bin {{ ftpdctl_bin }}
raw ssh_keygen_bin {{ ssh_keygen_bin }}
raw perl_bin {{ perl_bin }}
raw template_monitor {{ template_monitor }}
[instance-default]
......
......@@ -40,10 +40,7 @@ context =
key ftpasswd_bin proftpd-output:ftpasswd
key ftpdctl_bin proftpd-output:ftpdctl
key ssh_keygen_bin openssh-output:keygen
key perl_bin proftpd-output:perl
raw template_monitor ${monitor2-template:rendered}
[versions]
collective.recipe.environment = 1.1.0
collective.recipe.grp = 1.1.0
plone.recipe.command = 1.1
......@@ -175,5 +175,4 @@ gitdb = 0.6.4
gunicorn = 19.10.0
prettytable = 0.7.2
pycurl = 7.43.0
collective.recipe.environment = 0.2.0
smmap = 0.9.0
......@@ -98,15 +98,12 @@ url = ${:_profile_base_location_}/${:filename}
[mariadb-start-clone-from-backup]
<= download-base
mode = 755
[mariadb-resiliency-after-import-script]
<= download-base
mode = 755
[mariadb-slow-query-report-script]
<= download-base
mode = 755
[template-mariadb]
<= download-base
......@@ -557,6 +554,9 @@ eggs = ${neoppod:eggs}
zope.globalrequest
waitress
# OpenId Connect
oic
# parameterizing the version of the generated python interpreter name by the
# python section version causes dependency between this egg section and the
# installation of python, which we don't want on an instance
......@@ -756,3 +756,11 @@ beautifulsoup4 = 4.8.2
WebOb = 1.8.5
soupsieve = 1.9.5
eggtestinfo = 0.3
oic = 0.15.1
Beaker = 1.11.0
Mako = 1.1.4
pyjwkest = 1.4.2
alabaster = 0.7.12
future = 0.18.2
pycryptodomex = 3.10.1
......@@ -26,7 +26,6 @@ parts =
recipe = zc.recipe.egg
eggs =
collective.recipe.template
collective.recipe.environment
#----------------
#--
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment