diff --git a/uwsgi-python/handlers/main.yml b/uwsgi-python/handlers/main.yml index 6943805afc75260e55fceb17290bc5f5ad60d309..28c6b49e21c4b28e5777a20e6a72e553e58198da 100644 --- a/uwsgi-python/handlers/main.yml +++ b/uwsgi-python/handlers/main.yml @@ -125,3 +125,6 @@ - name: restart uwsgi instance darlehen service: name="uwsgi@darlehen" state=restarted + +- name: restart uwsgi instance etherpad-api-proxy + service: name="uwsgi@etherpad-api-proxy" state=restarted diff --git a/uwsgi-python/templates/apps/etherpad-api-proxy.j2 b/uwsgi-python/templates/apps/etherpad-api-proxy.j2 new file mode 100644 index 0000000000000000000000000000000000000000..50688b07b83f8f7d3b09139ee0b97533f2ad6dc6 --- /dev/null +++ b/uwsgi-python/templates/apps/etherpad-api-proxy.j2 @@ -0,0 +1,10 @@ +[upstream] +url = "{{etherpad_api_proxy_upstream_url}}" +api_key = "{{etherpad_api_proxy_upstream_api_key}}" + +{% for account in etherpad_api_proxy_accounts %} +[[api_keys]] +orga = "{{account.name}}" +api_key = "{{account.api_key}}" + +{% endfor %} diff --git a/uwsgi-python/templates/apps/protokollsystem.j2 b/uwsgi-python/templates/apps/protokollsystem.j2 index 4f57292927cff6eae5ce37efbaabf79068085241..63a9cbc91c232cbcaf2eef78f24ef23398d55ecd 100644 --- a/uwsgi-python/templates/apps/protokollsystem.j2 +++ b/uwsgi-python/templates/apps/protokollsystem.j2 @@ -55,11 +55,13 @@ PRINTING_PRINTERS = { ETHERPAD_ACTIVE = {{ protokolle_etherpad }} ETHERPAD_URL = "{{ protokolle_etherpad_url }}" +ETHERPAD_API_URL = "{{ protokolle_etherpad_api_url }}" +ETHERPAD_APIKEY = "{{ protokolle_etherpad_apikey }}" EMPTY_ETHERPAD = """Welcome to Etherpad! This pad text is synchronized as you type, so that everyone viewing this page sees the same text. This allows you to collaborate seamlessly on documents! -Get involved with Etherpad at http://etherpad.org +Get involved with Etherpad at https://etherpad.org """ diff --git a/uwsgi-python/vars/etherpad-api-proxy.yml b/uwsgi-python/vars/etherpad-api-proxy.yml new file mode 100644 index 0000000000000000000000000000000000000000..feb8a9710ddf778237881cbdd7f6b384ae04e8f7 --- /dev/null +++ b/uwsgi-python/vars/etherpad-api-proxy.yml @@ -0,0 +1,30 @@ +--- + +app_name: etherpad-api-proxy +app_user: etherpad-api-proxy +app_group: etherpad-api-proxy +app_home: /var/www/etherpad-api-proxy +app_path: /var/www/etherpad-api-proxy +app_python_version: 3 +app_venv: /var/www/etherpad-api-proxy/venv/ +app_program: proxy.py +app_callable: app +app_command: "" +app_mountpoint: / +app_service_env: [] +app_mules: 0 +app_enable_threads: false +app_uwsgi_options: [] + +app_db_name: '' +app_db_type: '' + +app_additional_software: [] + +app_deploy_key: '' +app_git_url: 'https://git.fsmpi.rwth-aachen.de/infra/etherpad-api-proxy.git' +app_git_version: HEAD + +app_requirements_file: requirements.txt +app_config_file: 'config.toml' +app_secret_config: false