mirror of
				https://github.com/kevinveenbirkenbach/computer-playbook.git
				synced 2025-10-31 10:19:09 +00:00 
			
		
		
		
	Implemented espocrm draft
This commit is contained in:
		
							
								
								
									
										39
									
								
								roles/docker-espocrm/templates/docker-compose.yml.j2
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										39
									
								
								roles/docker-espocrm/templates/docker-compose.yml.j2
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,39 @@ | ||||
| services: | ||||
|  | ||||
| {% include 'roles/docker-central-database/templates/services/' + database_type + '.yml.j2' %} | ||||
|  | ||||
|   web: | ||||
|     image: espocrm/espocrm:{{ applications.espocrm.version }} | ||||
| {% include 'roles/docker-compose/templates/services/base.yml.j2' %} | ||||
|     environment: | ||||
|       - DATABASE_HOST={{ database_host }} | ||||
|       - DATABASE_PORT={{ database_port }} | ||||
|       - DATABASE_NAME={{ database_name }} | ||||
|       - DATABASE_USER={{ database_username }} | ||||
|       - DATABASE_PASSWORD={{ database_password }} | ||||
|       - CRON=disable  # cron handled by separate service | ||||
|     command: apache2-foreground | ||||
|     healthcheck: | ||||
|       test: ["CMD", "curl", "-f", "http://localhost/" ] | ||||
|     ports: | ||||
|       - "127.0.0.1:{{ ports.localhost.http[application_id] }}:80" | ||||
| {% include 'templates/docker/container/depends-on-database.yml.j2' %} | ||||
| {% include 'templates/docker/container/networks.yml.j2' %} | ||||
|     volumes: | ||||
|       - data:/var/www/html | ||||
|  | ||||
|   cron: | ||||
|     image: espocrm/espocrm:{{ applications.espocrm.version }} | ||||
|     command: /usr/local/bin/cron.sh | ||||
|     restart: unless-stopped | ||||
| {% include 'templates/docker/container/depends-on-database.yml.j2' %} | ||||
|     volumes: | ||||
|       - data:/var/www/html | ||||
| {% include 'templates/docker/container/networks.yml.j2' %} | ||||
|     healthcheck: | ||||
|       test: ["CMD", "pgrep", "cron"] | ||||
|  | ||||
| {% include 'templates/docker/compose/volumes.yml.j2' %} | ||||
|   data: | ||||
|  | ||||
| {% include 'templates/docker/compose/networks.yml.j2' %} | ||||
							
								
								
									
										38
									
								
								roles/docker-espocrm/templates/env.j2
									
									
									
									
									
										Normal file
									
								
							
							
						
						
									
										38
									
								
								roles/docker-espocrm/templates/env.j2
									
									
									
									
									
										Normal file
									
								
							| @@ -0,0 +1,38 @@ | ||||
| # EspoCRM environment | ||||
| # Database connection | ||||
| DATABASE_HOST={{ database_host }} | ||||
| DATABASE_PORT={{ database_port }} | ||||
| DATABASE_NAME={{ database_name }} | ||||
| DATABASE_USER={{ database_username }} | ||||
| DATABASE_PASSWORD={{ database_password }} | ||||
|  | ||||
| # SMTP settings (example) | ||||
| SMTP_HOST={{ system_email.host }} | ||||
| SMTP_PORT={{ system_email.port }} | ||||
| SMTP_USER={{ users['no-reply'].email }} | ||||
| SMTP_PASS={{ users['no-reply'].mailu_token }} | ||||
| SMTP_SECURE=tls | ||||
|  | ||||
| ################################### | ||||
| # LDAP settings (optional) | ||||
| ################################### | ||||
| {% if applications[application_id].features.ldap | bool %} | ||||
| LDAP_ENABLED=true | ||||
| LDAP_HOST={{ ldap.server.domain }} | ||||
| LDAP_PORT={{ ldap.server.port }} | ||||
| LDAP_BASE_DN={{ ldap.dn.users }} | ||||
| LDAP_BIND_DN={{ ldap.dn.administrator }} | ||||
| LDAP_BIND_PASSWORD={{ ldap.bind_credential }} | ||||
| LDAP_UID_ATTRIBUTE={{ ldap.attributes.user_id }} | ||||
| {% endif %} | ||||
|  | ||||
| ################################### | ||||
| # OpenID Connect (OIDC) settings (optional) | ||||
| ################################### | ||||
| {% if applications[application_id].features.oidc | bool %} | ||||
| OIDC_ENABLED=true | ||||
| OIDC_ISSUER_URL={{ oidc.client.issuer_url }} | ||||
| OIDC_CLIENT_ID={{ oidc.client.id }} | ||||
| OIDC_CLIENT_SECRET={{ oidc.client.secret }} | ||||
| OIDC_REDIRECT_URI=https://{{ domains[application_id] }}/oidc/callback | ||||
| {% endif %} | ||||
		Reference in New Issue
	
	Block a user