mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-09-10 04:25:20 +02:00
feat(magento): switch to ghcr.io/alexcheng1982/docker-magento2:2.4.6-p3; update Compose/Env/Tasks/Docs
• Docs: updated to MAGENTO_VOLUME; removed Installation/User_Administration guides • Compose: volume path → /var/www/html; switched variables to MAGENTO_*/MYSQL_*/OPENSEARCH_* • Env: new variable set + APACHE_SERVERNAME • Task: setup:install via docker compose exec (multiline form) • Schema: removed obsolete credentials definition Link: https://chatgpt.com/share/68b8dc30-361c-800f-aa69-88df514cb160
This commit is contained in:
@@ -1,34 +1,33 @@
|
||||
{% include 'roles/docker-compose/templates/base.yml.j2' %}
|
||||
|
||||
application:
|
||||
{% set container_port = 8080 %}
|
||||
{% set container_port = 80 %}
|
||||
{% include 'roles/docker-container/templates/base.yml.j2' %}
|
||||
image: "{{ magento_image }}:{{ magento_version }}"
|
||||
container_name: "{{ magento_name }}"
|
||||
image: "{{ MAGENTO_IMAGE }}:{{ MAGENTO_VERSION }}"
|
||||
container_name: "{{ MAGENTO_CONTAINER }}"
|
||||
ports:
|
||||
- "127.0.0.1:{{ ports.localhost.http[application_id] }}:{{ container_port }}"
|
||||
volumes:
|
||||
- "data:/bitnami/magento"
|
||||
- "data:/var/www/html"
|
||||
{% include 'roles/docker-container/templates/depends_on/dmbs_excl.yml.j2' %}
|
||||
depends_on:
|
||||
- search
|
||||
# search:
|
||||
# condition: service_healthy
|
||||
{% include 'roles/docker-container/templates/healthcheck/tcp.yml.j2' %}
|
||||
{% include 'roles/docker-container/templates/networks.yml.j2' %}
|
||||
|
||||
search:
|
||||
{% set container_port = 9200 %}
|
||||
image: "{{ magento_search_image }}:{{ magento_search_version }}"
|
||||
container_name: "{{ magento_search_name }}"
|
||||
image: "{{ MAGENTO_SEARCH_IMAGE }}:{{ MAGENTO_SEARCH_VERSION }}"
|
||||
container_name: "{{ MAGENTO_SEARCH_NAME }}"
|
||||
{% include 'roles/docker-container/templates/base.yml.j2' %}
|
||||
environment:
|
||||
- discovery.type=single-node
|
||||
- plugins.security.disabled=true
|
||||
- OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m
|
||||
{% include 'roles/docker-container/templates/healthcheck/tcp.yml.j2' %}
|
||||
{% include 'roles/docker-container/templates/networks.yml.j2' %}
|
||||
|
||||
{% include 'roles/docker-compose/templates/volumes.yml.j2' %}
|
||||
data:
|
||||
name: {{ magento_data }}
|
||||
name: {{ MAGENTO_VOLUME }}
|
||||
|
||||
{% include 'roles/docker-compose/templates/networks.yml.j2' %}
|
||||
|
@@ -3,30 +3,32 @@
|
||||
# - https://github.com/bitnami/containers/tree/main/bitnami/magento
|
||||
|
||||
# Host & URLs
|
||||
MAGENTO_HOST="{{ domains | get_domain(application_id) }}"
|
||||
MAGENTO_BASE_URL="{{ domains | get_url(application_id, WEB_PROTOCOL) }}/"
|
||||
MAGENTO_ENABLE_HTTPS={{ (WEB_PORT == 443) | string | lower }}
|
||||
MAGENTO_URL="{{ MAGENTO_URL }}"
|
||||
MAGENTO_BACKEND_FRONTNAME="admin"
|
||||
MAGENTO_USE_SECURE={{ (WEB_PORT == 443) | ternary('1','0') }}
|
||||
MAGENTO_BASE_URL_SECURE={{ (WEB_PORT == 443) | ternary('1','0') }}
|
||||
MAGENTO_USE_SECURE_ADMIN={{ (WEB_PORT == 443) | ternary('1','0') }}
|
||||
|
||||
# Admin (seed from global administrator)
|
||||
MAGENTO_USERNAME="{{ users.administrator.username }}"
|
||||
MAGENTO_PASSWORD="{{ applications | get_app_conf(application_id, 'credentials.admin_password') }}"
|
||||
MAGENTO_EMAIL="{{ users.administrator.email }}"
|
||||
MAGENTO_FIRST_NAME="{{ users.administrator.firstname | default('Admin') }}"
|
||||
MAGENTO_LAST_NAME="{{ users.administrator.lastname | default('User') }}"
|
||||
MAGENTO_ADMIN_USERNAME="{{ users.administrator.username }}"
|
||||
MAGENTO_ADMIN_PASSWORD="{{ users.administrator.password }}"
|
||||
MAGENTO_ADMIN_EMAIL="{{ users.administrator.email }}"
|
||||
MAGENTO_ADMIN_FIRSTNAME="{{ users.administrator.firstname | default('Admin') }}"
|
||||
MAGENTO_ADMIN_LASTNAME="{{ users.administrator.lastname | default('User') }}"
|
||||
|
||||
# Database (central DB preferred)
|
||||
MARIADB_HOST="{{ database_host }}"
|
||||
MARIADB_PORT_NUMBER="{{ database_port }}"
|
||||
MAGENTO_DATABASE_USER="{{ database_username }}"
|
||||
MAGENTO_DATABASE_PASSWORD="{{ database_password }}"
|
||||
MAGENTO_DATABASE_NAME="{{ database_name }}"
|
||||
MYSQL_HOST="{{ database_host }}"
|
||||
MYSQL_PORT="{{ database_port }}"
|
||||
MYSQL_USER="{{ database_username }}"
|
||||
MYSQL_PASSWORD="{{ database_password }}"
|
||||
MYSQL_DATABASE="{{ database_name }}"
|
||||
|
||||
# Search (Magento 2.4+)
|
||||
MAGENTO_SEARCH_ENGINE="opensearch"
|
||||
OPENSEARCH_HOST="search"
|
||||
OPENSEARCH_PORT_NUMBER="9200"
|
||||
OPENSEARCH_INITIAL_ADMIN_PASSWORD="{{ users.administrator.password }}"
|
||||
|
||||
# SMTP
|
||||
# SMTP (post-install you’ll wire these in Magento admin or env.php)
|
||||
SMTP_HOST="{{ SYSTEM_EMAIL.HOST }}"
|
||||
SMTP_PORT="{{ SYSTEM_EMAIL.PORT }}"
|
||||
SMTP_USER="{{ users['no-reply'].email }}"
|
||||
@@ -34,6 +36,6 @@ SMTP_PASSWORD="{{ users['no-reply'].mailu_token }}"
|
||||
SMTP_PROTOCOL={{ SYSTEM_EMAIL.TLS | ternary('tls','ssl') }}
|
||||
|
||||
# Misc
|
||||
ALLOW_EMPTY_PASSWORD="no"
|
||||
BITNAMI_DEBUG="false"
|
||||
PHP_MEMORY_LIMIT="1024M"
|
||||
PHP_MEMORY_LIMIT="768M"
|
||||
|
||||
APACHE_SERVERNAME={{ MAGENTO_DOMAIN }}
|
Reference in New Issue
Block a user