forked from ISTI-ansible-roles/ansible-roles
library/roles/sharelatex: Add some more env variables to handle the load balancer securely.
This commit is contained in:
parent
72882b275c
commit
f7615fa798
|
@ -11,6 +11,7 @@ sharelatex_hostname: '{{ ansible_fqdn }}'
|
||||||
sharelatex_local_mongodb: False
|
sharelatex_local_mongodb: False
|
||||||
sharelatex_local_redis: False
|
sharelatex_local_redis: False
|
||||||
sharelatex_local_nginx: False
|
sharelatex_local_nginx: False
|
||||||
|
sharelatex_secure_cookie: False
|
||||||
|
|
||||||
sharelatex_mongodb_host: 'localhost'
|
sharelatex_mongodb_host: 'localhost'
|
||||||
sharelatex_mongodb_db: 'sharelatex'
|
sharelatex_mongodb_db: 'sharelatex'
|
||||||
|
|
|
@ -24,7 +24,7 @@
|
||||||
become: True
|
become: True
|
||||||
become_user: docker
|
become_user: docker
|
||||||
#command: docker run -v {{ sharelatex_host_data_dir }}:{{ sharelatex_container_data_dir }} -p {{ sharelatex_container_public_port }}:{{ sharelatex_container_local_port }} --name={{ sharelatex_container_name }} --env-file {{ docker_user_home }}/sharelatex/sharelatex-env.sh {{ sharelatex_docker_image }}
|
#command: docker run -v {{ sharelatex_host_data_dir }}:{{ sharelatex_container_data_dir }} -p {{ sharelatex_container_public_port }}:{{ sharelatex_container_local_port }} --name={{ sharelatex_container_name }} --env-file {{ docker_user_home }}/sharelatex/sharelatex-env.sh {{ sharelatex_docker_image }}
|
||||||
docker_container: name={{ sharelatex_container_name }} volumes:{{ sharelatex_host_data_dir }}:{{ sharelatex_container_data_dir }} published_ports={{ sharelatex_container_public_port }}:{{ sharelatex_container_local_port }} env_file={{ docker_user_home }}/sharelatex/sharelatex-env.sh image={{ sharelatex_docker_image }} state=started
|
docker_container: name={{ sharelatex_container_name }} volumes:{{ sharelatex_host_data_dir }}:{{ sharelatex_container_data_dir }} published_ports={{ sharelatex_container_public_port }}:{{ sharelatex_container_local_port }} env_file={{ docker_user_home }}/sharelatex/sharelatex-env.sh image={{ sharelatex_docker_image }} state=started keep_volumes=yes pull=yes
|
||||||
when: docker_run_as_docker_user
|
when: docker_run_as_docker_user
|
||||||
|
|
||||||
- name: Start the Sharelatex docker container as root
|
- name: Start the Sharelatex docker container as root
|
||||||
|
|
|
@ -2,8 +2,14 @@ SHARELATEX_MONGO_URL={{ sharelatex_mongodb_url }}
|
||||||
SHARELATEX_REDIS_HOST={{ sharelatex_redis_host }}
|
SHARELATEX_REDIS_HOST={{ sharelatex_redis_host }}
|
||||||
SHARELATEX_APP_NAME='{{ sharelatex_app_name }}'
|
SHARELATEX_APP_NAME='{{ sharelatex_app_name }}'
|
||||||
SHARELATEX_SITE_URL={{ sharelatex_site_url }}
|
SHARELATEX_SITE_URL={{ sharelatex_site_url }}
|
||||||
SHARELATEX_NAV_TITLE='D4Science ShareLaTeX Service'
|
SHARELATEX_NAV_TITLE='{{ sharelatex_app_name }}'
|
||||||
SHARELATEX_BEHIND_PROXY='{{ sharelatex_behind_proxy }}'
|
SHARELATEX_BEHIND_PROXY='{{ sharelatex_behind_proxy }}'
|
||||||
|
{% if sharelatex_secure_cookie %}
|
||||||
|
SHARELATEX_SECURE_COOKIE=true
|
||||||
|
{% endif %}
|
||||||
|
{% if sharelatex_session_secret is defined %}
|
||||||
|
SHARELATEX_SESSION_SECRET={{ sharelatex_session_secret }}
|
||||||
|
{% endif %}
|
||||||
{% if sharelatex_header_image_url is defined %}
|
{% if sharelatex_header_image_url is defined %}
|
||||||
SHARELATEX_HEADER_IMAGE_URL={{ sharelatex_header_image_url }}
|
SHARELATEX_HEADER_IMAGE_URL={{ sharelatex_header_image_url }}
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
Loading…
Reference in New Issue