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
Tom Niget
slapos
Commits
d48ecc9c
Commit
d48ecc9c
authored
Jan 20, 2025
by
Tom Niget
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
postgresql
parent
c9ee9f37
Changes
5
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
89 additions
and
25 deletions
+89
-25
software/mail-server/buildout.hash.cfg
software/mail-server/buildout.hash.cfg
+3
-3
software/mail-server/instance-default.cfg.in
software/mail-server/instance-default.cfg.in
+78
-17
software/mail-server/instance.cfg.in
software/mail-server/instance.cfg.in
+1
-0
software/mail-server/php.ini.in
software/mail-server/php.ini.in
+4
-4
software/mail-server/software.cfg
software/mail-server/software.cfg
+3
-1
No files found.
software/mail-server/buildout.hash.cfg
View file @
d48ecc9c
...
...
@@ -15,11 +15,11 @@
[template]
filename = instance.cfg.in
md5sum =
ec2cac2499cb1748402da9cb73e81a1
e
md5sum =
3b22160ee34e004983fd17c503391ad
e
[template-default]
_update_hash_filename_ = instance-default.cfg.in
md5sum =
10ff0aaefca7ad7f2746fbfa0b3abc0e
md5sum =
c71a9dca86ef4e2115ecaed12fb9b3e3
[dovecot.jinja2.conf]
_update_hash_filename_ = dovecot.jinja2.conf
...
...
@@ -47,7 +47,7 @@ md5sum = e49410f0a4bf28993a56bb28aff0a6f0
[template-php.ini]
filename = php.ini.in
md5sum =
677e1185a99d337cd1be778c548a6d30
md5sum =
eccdfb6d780d9aa4cf66401191ab16a6
[template-apache-httpd]
filename = apache-httpd.conf.in
...
...
software/mail-server/instance-default.cfg.in
View file @
d48ecc9c
...
...
@@ -50,6 +50,7 @@ tmp-php = ${:tmp}/php
upload-tmp = ${:tmp}/upload
www = ${:srv}/www/
apache.d = ${:etc}/apache.d
srv-backup = ${:srv}/backup
[slap-configuration]
recipe = slapos.cookbook:slapconfiguration.serialised
...
...
@@ -201,14 +202,14 @@ hash-files =
${postfix-conf-main:output}
${postfix-wrapper:output}
[apache-php-service]
recipe = slapos.cookbook:wrapper
command-line = ${ca-apache-php:wrapper}
wrapper-path = ${directory:service}/apache-php
hash-existing-files = ${buildout:directory}/software_release/buildout.cfg
depends =
${copy-application:recipe}
${apache-graceful:recipe}
#
[apache-php-service]
#
recipe = slapos.cookbook:wrapper
#
command-line = ${ca-apache-php:wrapper}
#
wrapper-path = ${directory:service}/apache-php
#
hash-existing-files = ${buildout:directory}/software_release/buildout.cfg
#
depends =
#
${copy-application:recipe}
#
${apache-graceful:recipe}
[apache-graceful]
recipe = collective.recipe.template
...
...
@@ -243,6 +244,13 @@ cert-file = ${ca-directory:certs}/httpd.crt
key-file = ${ca-directory:certs}/httpd.key
apache-config-dir = ${directory:apache.d}
[postgresql-backup-crontab-entry]
recipe = slapos.cookbook:cron.d
name = ${:_buildout_section_name_}
cron-entries = ${cron:cron-entries}
time = daily
command = ${postgresql-backup:wrapper-path}
[publish-connection-information]
<= monitor-publish
recipe = slapos.cookbook:publish
...
...
@@ -251,10 +259,28 @@ smtp-port = 10025
imap-smtp-ipv6 = ${slap-configuration:ipv6-random}
domain = ${request-dns-entry:connection-domain}
backend-url = ${apache-php-configuration:url}
backup-crontab = ${postgresql-backup-crontab-entry:name}
{% if apache_parameter_dict['publish-frontend'] -%}
#url = ${lamp-frontend-promise:url}
{% endif -%}
[postgresql-backup]
recipe = slapos.cookbook:wrapper
wrapper-path = ${directory:bin}/${:_buildout_section_name_}
# XXX there's a recipe for backup in slapos cookbook, but it does not create
# the backup file in an atomic way, which is not acceptable here, because we
# don't want to risk pulling a partial file. To prevent this, we create a
# temp file and move it when finished.
command-line =
sh -c "${postgresql:bin}/pg_dump \
-h ${postgresql:pgdata-directory} \
-U ${postgresql:superuser} \
--format=custom \
-f ${:backup-file}.tmp \
${postgresql:dbname} \
&& mv ${:backup-file}.tmp ${:backup-file}"
backup-file = ${directory:srv-backup}/backup.pg_dump
[request-frontend]
<= slap-connection
recipe = slapos.cookbook:requestoptional
...
...
@@ -388,7 +414,7 @@ parts =
imap-listen-promise
smtp-listen-promise
php.ini-conf
apache-php-service
#
apache-php-service
{{ part_list | join('\n ') }}
{% if slapparameter_dict.get('request_dns', '') %}
request-dns-entry
...
...
@@ -399,17 +425,52 @@ develop-eggs-directory = {{ develop_eggs_directory }}
offline= true
[mariadb-urlparse]
recipe = slapos.cookbook:urlparse
url = {{ slapparameter_dict['database-list'][0] }}
[postgresql-password]
recipe = slapos.cookbook:generate.password
[postgresql]
recipe = slapos.cookbook:postgres
bin = {{ postgresql_location }}/bin
services = ${directory:service}
dbname = dependency-track_db
superuser = dependency-track-psql
password = ${postgresql-password:passwd}
pgdata-directory = ${directory:srv}/postgresql
ipv4 =
# disable listening on ipv6
ipv6 = ${slap-configuration:ipv6-random}
port = 5432
promises = $${postgresql-promise:name}
[postgresql-psql]
recipe = slapos.cookbook:wrapper
wrapper-path = $${directory:bin}/$${:_buildout_section_name_}
command-line =
$${postgresql:bin}/psql
-h $${postgresql:pgdata-directory}
-U $${postgresql:superuser}
-d $${postgresql:dbname}
[postgresql-promise]
<= monitor-promise-base
promise = check_command_execute
name = promise-postgresql.py
config-command = $${postgresql-psql:wrapper-path} -c '\q'
#[mariadb-urlparse]
#recipe = slapos.cookbook:urlparse
#url = slapparameter_dict['database-list'][0]
[instance-parameter]
# snappymail = ${:document-root}
db-user = ${mariadb-urlparse:username}
db-password = ${mariadb-urlparse:password}
db-name = ${mariadb-urlparse:path}
db-host = ${mariadb-urlparse:host}
db-port = ${mariadb-urlparse:port}
#
db-user = ${mariadb-urlparse:username}
#
db-password = ${mariadb-urlparse:password}
#
db-name = ${mariadb-urlparse:path}
#
db-host = ${mariadb-urlparse:host}
#
db-port = ${mariadb-urlparse:port}
document-root = ${apache-php-configuration:document-root}
backend-url = ${apache-php-configuration:url}
php-bin = {{ apache_parameter_dict['apache-php-location'] }}/bin/php
...
...
software/mail-server/instance.cfg.in
View file @
d48ecc9c
...
...
@@ -46,6 +46,7 @@ extra-context =
key ipv4_set slap-configuration:ipv4
key ipv6_set slap-configuration:ipv6
raw bin_directory {{ bin_directory }}
raw postgresql_location {{ postgresql_location }}
section mariadb_parameter_dict dynamic-template-mariadb-parameters
...
...
software/mail-server/php.ini.in
View file @
d48ecc9c
...
...
@@ -9,7 +9,7 @@ log_errors = On
log_errors_max_len = 1024
ignore_repeated_errors = Off
ignore_repeated_source = Off
session.save_path = "{{ parameter_dict['tmp-dir'] }}"
session.save_path = "{{
apache_
parameter_dict['tmp-dir'] }}"
session.auto_start = 0
date.timezone = {{ instance_dict.get('php.date.timezone', 'Europe/Paris') }}
file_uploads = On
...
...
@@ -24,8 +24,8 @@ output_buffering = {{ instance_dict.get('php.output_buffering', 4096) }}
max_file_uploads = {{ instance_dict.get('php.max_file_uploads', 100) }}
#extension_dir="./"#
sys_temp_dir="{{ parameter_dict['tmp-dir'] }}"
upload_tmp_dir="{{ parameter_dict['php-upload-dir'] }}"
sys_temp_dir="{{
apache_
parameter_dict['tmp-dir'] }}"
upload_tmp_dir="{{
apache_
parameter_dict['php-upload-dir'] }}"
zend_extension=opcache
...
...
@@ -48,7 +48,7 @@ apc.max_file_size=5M
apc.cache_by_default=1
apc.use_request_time=1
apc.slam_defense=0
apc.mmap_file_mask="{{ parameter_dict['tmp-dir'] }}/apc.XXXXXX"
apc.mmap_file_mask="{{
apache_
parameter_dict['tmp-dir'] }}/apc.XXXXXX"
apc.stat_ctime=0
apc.canonicalize=1
apc.write_lock=1
...
...
software/mail-server/software.cfg
View file @
d48ecc9c
...
...
@@ -4,6 +4,7 @@ extends =
../../component/postfix/buildout.cfg
../../component/dovecot/buildout.cfg
# ../../component/mariadb/buildout.cfg
../../component/postgresql/buildout.cfg
../../stack/slapos.cfg
../../stack/monitor/buildout.cfg
../../stack/erp5/buildout.cfg
...
...
@@ -15,8 +16,8 @@ parts =
slapos-cookbook
template
dovecot
postgresql
postfix
mariadb
[postfix]
...
...
@@ -46,6 +47,7 @@ context =
# key xz_utils_location xz-utils:location
key template_monitor monitor2-template:output
key mariadb_link_binary template-mariadb:link-binary
key postgresql_location postgresql:location
key mariadb_location mariadb:location
key mariadb_resiliency_after_import_script mariadb-resiliency-after-import-script:target
key mariadb_slow_query_report_script mariadb-slow-query-report-script:target
...
...
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