# Ansible - Role - ERDDAP A role that installs the ERDDAP Docker container. This role will - create 2 linux users - create some directories for the container files and volumes - create the docker compose file - configure and customize the ERDDAP configuration files and cotainer entrypoint ## Role Variables In the `defaults\main.yaml` file you can find all the role variables. You can find below a description of the main variables or variables group ``` # This set the directory where will be create the docker compose manifest and all the needed directories. directory_base: /opt/data00/customdocker/ # This the directory where are the external data files that ERDDAP will read. directory_external_data: fullpath: "/opt/data00/appdata/" create_if_not_exists: true # If you want to create the yaml of a docker stack (aka customer project name) enable it and set # the stack name. stack: enable: true name: "XXX_dockstackname_XXX" # WARNING: do not add trailing / directory_relative_path: 'XXX_dockstackname_XXX' start_after_configuration: true # user_list: create the users that the container will use to run and access the data files. # DO NOT change the user order in the list user_list: - name: 'usr{{ stack.name }}' groups: uid: 2000 gid: 2000 - name: usrtomcat groups: 'usr{{ stack.name }}' uid: 2001 gid: 2001 # ERDDAP Specific variables erddap: content_setup_xml_replace_items: # bigParentDirectory - Same as volume mounted inside the container - regexp: /home/yourName/erddap/ replace: /erddapData/ - regexp: http://localhost:8080 replace: http://XXX_ERDDAP_webDomainOrIPv4_XXX - regexp: replace: https://XXX_ERDDAP_webDomainOrIPv4_XXX - regexp: your.email@yourInstitution.edu replace: asd@asd.com - regexp: Your Institution replace: XXX_MyInstutionString_XXX - regexp: Your Institution's or Group's Url replace: https://XXX_MyInstitutionUrl_XXX - regexp: Your Name replace: XXX_YourName_XXX - regexp: ERDDAP administrator replace: ERDDAP administrator # The \+ is for the python regexp - The real default value is +1 999-999-9999 - regexp: \+1 999-999-9999 replace: 000000000 - regexp: 123 Main St. replace: XXX_MyAddress_XXX - regexp: Some Town replace: XXX_YourTown_XXX - regexp: CA replace: XXX_State_XXX - regexp: 99999 replace: XXX_PostCode_XXX - regexp: USA replace: XXX_Country_XXX - regexp: your.email@yourCompany.com replace: XXX_adminMail_XXX - regexp: CHANGE THIS TO YOUR FAVORITE QUOTE replace: XXX_MyFlagKey_XXX content_setup_xml_replace_email: false content_setup_xml_replace_email_items: - regexp: your.email@yourCompany.com replace: XXX_YourEmail_XXX - regexp: your.email@yourCompany.com replace: XXX_YourEmailUsername_XXX - regexp: yourPassword replace: XXX_YourPassword_XXX - regexp: replace: - regexp: your.smtp.host.edu replace: XXX_YourEmailSmtp_XXX - regexp: 25 replace: XXX_YourEmailSmtpPort_XXX # This set which content.erddap archive will be deployed. It depends from the ERDDAP version. See the ERDDAP webpage. content_archive_data_name: "content.erddap_v214.tar.gz" # This is the main ERDDAP data directory bigParentDirectory: /erddapData/ # This enable the container SSL endpoint. This is useful if ERDDAP is behind a reverse proxy. Because some web pages doesn't work the comunication from are HTTPS (reverse proxy) <---> HTTP (erddap). # The reverse proxy must not check the certificate expire date and CN. tomcatSsl: enable: true container_certPath: "erddap/data/erddap/ssl/erddap-self.localhost_2122.pfx" certType: "PKCS12" certPassword: "*********" container: image: axiom/docker-erddap:2.23-jdk17-openjdk containername: '{{ stack.name }}-erddap' # start_after_configuration - If stack is enabled, this variable is not used. start_after_configuration: true # container.volume_directory_relative_path_list: do not change the directory order in the list volume_directory_relative_path_list: - name: '{{ stack.name }}-erddap-docker/volumes/Content' - name: '{{ stack.name }}-erddap-docker/volumes/Data' - name: '{{ stack.name }}-erddap-docker/volumes/erddapSSLCerts' - name: '{{ stack.name }}-erddap-docker/deployfiles' - name: '{{ stack.name }}-erddap-docker/deployfiles/erddap-docker' http_host_port: 12081 # https_host_port - Used if erddap.tomcatSsl.enable: true https_host_port: 12082 ```