php-xml
pngcrush
pngquant
+ python-is-python3
python3
python3-brotli
python3-bs4
python3-magic
python3-pil
python3-psycopg2
+ python3-venv
python3-pyproj
python3-gdal
gdal-bin
"memory_limit" => "128M",
"post_max_size" => "32M",
"upload_max_filesize" => "32M"
- php_admin_values "sendmail_path" => "/usr/sbin/sendmail -t -i -f #{name}@errol.openstreetmap.org",
+ php_admin_values "sendmail_path" => "/usr/sbin/sendmail -t -i -f #{name}@dev.openstreetmap.org",
"open_basedir" => "/home/#{name}/:/tmp/:/usr/share/php/"
php_flags "display_errors" => "on"
end
exec_start "#{node[:ruby][:bundle]} exec rails jobs:work"
restart "on-failure"
nice 10
- private_tmp true
- private_devices true
- protect_system "strict"
- protect_home true
+ sandbox :enable_network => true
+ restrict_address_families "AF_UNIX"
+ memory_deny_write_execute false
read_write_paths "/srv/%i.apis.dev.openstreetmap.org/logs"
- no_new_privileges true
end
systemd_service "cgimap@" do
user "apis"
exec_start "/srv/%i.apis.dev.openstreetmap.org/cgimap/openstreetmap-cgimap --daemon --port $CGIMAP_PORT --instances 5"
exec_reload "/bin/kill -HUP $MAINPID"
- private_tmp true
- private_devices true
- protect_system "strict"
- protect_home true
+ sandbox :enable_network => true
+ restrict_address_families "AF_UNIX"
read_write_paths ["/srv/%i.apis.dev.openstreetmap.org/logs", "/srv/%i.apis.dev.openstreetmap.org/rails/tmp"]
- no_new_privileges true
restart "on-failure"
end
action [:enable, :start]
supports :restart => true
subscribes :restart, "rails_port[#{site_name}]"
- subscribes :restart, "systemd_service[#{name}]"
+ subscribes :restart, "systemd_service[rails-jobs@]"
only_if "fgrep -q delayed_job #{rails_directory}/Gemfile.lock"
end
user "apis"
group "apis"
subscribes :run, "execute[#{cgimap_directory}/configure]", :immediately
- notifies :restart, "service[cgimap@#{name}]"
end
template "/etc/default/cgimap-#{name}" do
:database_port => node[:postgresql][:clusters][:"14/main"][:port],
:database_name => database_name,
:log_directory => log_directory
- notifies :restart, "service[cgimap@#{name}]"
end
service "cgimap@#{name}" do
action [:start, :enable]
+ subscribes :restart, "execute[#{cgimap_directory}/Makefile]"
+ subscribes :restart, "template[/etc/default/cgimap-#{name}]"
+ subscribes :restart, "systemd_service[cgimap@]"
end
end