diff --git a/config.ini b/config.ini new file mode 100644 index 0000000..4638d37 --- /dev/null +++ b/config.ini @@ -0,0 +1,36 @@ +[database] +; http://docs.sqlalchemy.org/en/rel_0_8/core/engines.html +url: postgresql://mandaye-meyzieu@/mandaye_meyzieu + +[dirs] +config_root: /etc/mandaye-meyzieu/sites-enabled +data_dir: /var/lib/mandaye-meyzieu/data +static_root: /usr/share/mandaye-meyzieu/static +static_url: /mandaye/static + +[debug] +debug: false +use_long_trace: true +log_debug: false +; you need to install python-raven for this feature +sentry_dsn: + +[mandaye] +toolbar: false +a2_auto_connection: false +auto_decompress: true +; if you want to encypt password set to true +; you need to install pycrypto for this feature +encrypt_sp_password: false +; if encrypt_sp_password then you need to choose a secret +; must be a 16, 24, or 32 bytes long +encrypt_secret: + +[session] +; file, dbm, memory or memcached +; if memcached you need to install python-memcached and memcached +type: file +url: +cookie_expires: true +timeout: 3600 +data_dir: /var/lib/mandaye-meyzieu/sessions diff --git a/dirs b/dirs index acea3be..235df7c 100644 --- a/dirs +++ b/dirs @@ -2,3 +2,9 @@ etc/mandaye-meyzieu etc/mandaye-meyzieu/certs etc/mandaye-meyzieu/sites-available etc/mandaye-meyzieu/sites-enabled +var/lib/mandaye-meyzieu +var/lib/mandaye-meyzieu/data +var/lib/mandaye-meyzieu/sessions +var/run/mandaye-meyzieu +var/log/mandaye-meyzieu +usr/share/mandaye-meyzieu diff --git a/install b/install index e28c784..9f2bc40 100644 --- a/install +++ b/install @@ -1 +1 @@ -debian/local_config.py /etc/mandaye-meyzieu/ +debian/config.ini /etc/mandaye-meyzieu/ diff --git a/local_config.py b/local_config.py deleted file mode 100644 index 9e0d26e..0000000 --- a/local_config.py +++ /dev/null @@ -1,42 +0,0 @@ -## SQL Backend config -# http://docs.sqlalchemy.org/en/rel_0_7/core/engines.html -# rfc 1738 https://tools.ietf.org/html/rfc1738 -# dialect+driver://username:password@host:port/database -db_url = 'postgresql://mandaye-meyzieu@/mandaye_meyzieu' - -## Logging configuration -debug = False - -# Configuration directory -config_root = '/etc/mandaye-meyzieu/sites-enabled' -# Static folder -static_root = '/usr/share/mandaye-meyzieu/static' -# Data directory -data_dir = '/var/lib/mandaye-meyzieu/data' - -# Raven Sentry configuration -raven_dsn = None - -## Email notification configuration -email_notification = False -smtp_host = 'localhost' -smtp_port = 25 -email_from = 'admin+mandaye-meyzieu@entrouvert.com' -email_to = ['admin+mandaye-meyzieu@entrouvert.com'] - - -## Session configuration -# http://beaker.readthedocs.org/en/latest/configuration.html#options-for-sessions-and-caching -session_opts = { - 'session.type': 'file', - 'session.cookie_expires': True, - 'session.timeout': 3600, - 'session.data_dir': '/var/lib/mandaye-meyzieu/sessions' -} - -## Encrypt service provider passwords with a secret -# You should install pycypto to use this feature -encrypt_sp_password = True -# Must be a 16, 24, or 32 bytes long -encrypt_secret = 'CHANGEME' - diff --git a/rules b/rules index a319c67..c0ff2e9 100755 --- a/rules +++ b/rules @@ -7,13 +7,4 @@ BUILD_DIR=$(CURDIR)/debian/mandaye-meyzieu override_dh_install: dh_install - for ver in $(shell pyversions -vr); do \ - ln -s /etc/mandaye-meyzieu/local_config.py $(BUILD_DIR)/usr/lib/python$$ver/dist-packages/rp_meyzieu/; \ - done - install -d -m 0755 $(BUILD_DIR)/var/lib/mandaye-meyzieu - install -d -m 0755 $(BUILD_DIR)/var/lib/mandaye-meyzieu/data - install -d -m 0750 $(BUILD_DIR)/var/lib/mandaye-meyzieu/sessions - install -d -m 0755 $(BUILD_DIR)/var/run/mandaye-meyzieu - install -d -m 0755 $(BUILD_DIR)/var/log/mandaye-meyzieu - install -d -m 0755 $(BUILD_DIR)/usr/share/mandaye-meyzieu cp -R rp_meyzieu/static $(BUILD_DIR)/usr/share/mandaye-meyzieu