#jinja2:lstrip_blocks: True {{ ansible_managed | comment }} version: '2.1' services: freshrss: container_name: {{ freshrss_container_name }} image: {{ freshrss_image }} restart: unless-stopped ports: - {{ freshrss_exposed_ip + ':' if freshrss_exposed_ip is defined else '' }}{{ freshrss_exposed_port }}:8080 volumes: - extensions:/var/www/app/extensions - data:/var/www/app/data {% if freshrss_extra_hosts | default([]) %} extra_hosts: {% for host in freshrss_extra_hosts %} - {{ '"' + host + '"' }} {% endfor %} {% endif %} environment: - FRESHRSS_ENVIRONMENT=production {% if freshrss_salt is defined and freshrss_salt %} - FRESHRSS_SALT={{ freshrss_salt }} {% endif %} - FRESHRSS_BASE_URL={{ freshrss_base_url }} - FRESHRSS_LANGUAGE={{ freshrss_language }} - FRESHRSS_TITLE={{ freshrss_title }} {% if freshrss_meta_description is defined and freshrss_meta_description %} - FRESHRSS_META_DESCRIPTION={{ freshrss_meta_description }} {% endif %} - FRESHRSS_DEFAULT_USER={{ freshrss_default_user }} - FRESHRSS_DEFAULT_PASSWORD={{ freshrss_default_password }} - FRESHRSS_ALLOW_ANONYMOUS={{ freshrss_allow_anonymous }} - FRESHRSS_ALLOW_ANONYMOUS_REFRESH={{ freshrss_allow_anonymous_refresh }} - FRESHRSS_AUTH_TYPE={{ freshrss_auth_type }} - FRESHRSS_API_ENABLED={{ freshrss_api_enabled }} - FRESHRSS_UNSAFE_AUTOLOGIN_ENABLED={{ freshrss_unsafe_autologin_enabled }} - FRESHRSS_SIMPLEPIE_SYSLOG_ENABLED={{ freshrss_simplepie_syslog_enabled }} - FRESHRSS_PUBSUBHUBBUB_ENABLED={{ freshrss_pubsubhubbub_enabled }} - FRESHRSS_ALLOW_ROBOTS={{ freshrss_allow_robots }} - FRESHRSS_ALLOW_REFERRER={{ freshrss_allow_referrer }} - FRESHRSS_LIMITS_COOKIE_DURATION={{ freshrss_limits_cookie_duration }} - FRESHRSS_LIMITS_CACHE_DURATION={{ freshrss_limits_cache_duration }} - FRESHRSS_LIMITS_TIMEOUT={{ freshrss_limits_timeout }} - FRESHRSS_LIMITS_MAX_INACTIVITY={{ freshrss_limits_max_inactivity }} - FRESHRSS_LIMITS_MAX_FEEDS={{ freshrss_limits_max_feeds }} - FRESHRSS_LIMITS_MAX_CATEGORIES={{ freshrss_limits_max_categories }} - FRESHRSS_LIMITS_MAX_REGISTRATIONS={{ freshrss_limits_max_registrations }} {% if freshrss_curlopt_ssl_verifyhost is defined and freshrss_curlopt_ssl_verifyhost %} - FRESHRSS_CURLOPT_SSL_VERIFYHOST={{ freshrss_curlopt_ssl_verifyhost }} {% endif %} {% if freshrss_curlopt_ssl_verifypeer is defined and freshrss_curlopt_ssl_verifypeer %} - FRESHRSS_CURLOPT_SSL_VERIFYPEER={{ freshrss_curlopt_ssl_verifypeer }} {% endif %} {% if freshrss_curlopt_proxytype is defined and freshrss_curlopt_proxytype %} - FRESHRSS_CURLOPT_PROXYTYPE={{ freshrss_curlopt_proxytype }} {% endif %} {% if freshrss_curlopt_proxy is defined and freshrss_curlopt_proxy %} - FRESHRSS_CURLOPT_PROXY={{ freshrss_curlopt_proxy }} {% endif %} {% if freshrss_curlopt_proxyport is defined and freshrss_curlopt_proxyport %} - FRESHRSS_CURLOPT_PROXYPORT={{ freshrss_curlopt_proxyport }} {% endif %} {% if freshrss_curlopt_proxyauth is defined and freshrss_curlopt_proxyauth %} - FRESHRSS_CURLOPT_PROXYAUTH={{ freshrss_curlopt_proxyauth }} {% endif %} {% if freshrss_curlopt_proxyuserpwd is defined and freshrss_curlopt_proxyuserpwd %} - FRESHRSS_CURLOPT_PROXYUSERPWD={{ freshrss_curlopt_proxyuserpwd }} {% endif %} - FRESHRSS_DB_TYPE=pgsql {% if ttrss_db_type == "pgsql" %} - FRESHRSS_DB_HOST={{ freshrss_db_server }};sslmode={{ freshrss_db_ssl_mode }} {% else %} - FRESHRSS_DB_HOST={{ freshrss_db_server }} {% endif %} - FRESHRSS_DB_SSL_ROOTCERT={{ freshrss_db_ssl_rootcert }} - FRESHRSS_DB_PORT={{ freshrss_db_port }} - FRESHRSS_DB_USER={{ freshrss_db_user }} - FRESHRSS_DB_PASSWORD={{ freshrss_db_password }} - FRESHRSS_DB_BASE={{ freshrss_db_name }} - FRESHRSS_DB_PREFIX=freshrss_ - FRESHRSS_EXTENSIONS_ENABLED={{ freshrss_extensions_enabled | join(',') }} {% if freshrss_memory_limit is defined %} mem_limit: {{ freshrss_memory_limit }} {% endif %} {% if freshrss_memory_reservation is defined %} mem_reservation: {{ freshrss_memory_reservation }} {% endif %} {% if freshrss_cpu_shares is defined %} cpu_shares: {{ freshrss_cpu_shares }} {% endif %} {% if not freshrss_cap_add | length == 0 %} cap_add: {% for item in freshrss_cap_add %} - {{ item }} {% endfor %} {% endif %} {% if not freshrss_cap_drop | length == 0 %} cap_drop: {% for item in freshrss_cap_drop %} - {{ item }} {% endfor %} {% endif %} {% if not freshrss_security_opt | length == 0 %} security_opt: {% for item in freshrss_security_opt %} - {{ item }} {% endfor %} {% endif %} healthcheck: {% for key, value in freshrss_healthcheck.items() %} {{ key }}: {{ value }} {% endfor %} {% if freshrss_pids_limit is defined %} pids_limit: {{ freshrss_pids_limit }} {% endif %} volumes: extensions: driver: local data: driver: local