Add customizations support to maubot
This commit is contained in:
@ -17,7 +17,6 @@ matrix_bot_maubot_path_prefix: /_matrix/maubot
|
||||
|
||||
matrix_bot_maubot_container_image_self_build: false
|
||||
matrix_bot_maubot_docker_repo: "https://mau.dev/maubot/maubot.git"
|
||||
matrix_bot_maubot_docker_src_files_path: "{{ matrix_bot_maubot_base_path }}/docker-src"
|
||||
matrix_bot_maubot_docker_repo_version: "{{ 'master' if matrix_bot_maubot_version == 'latest' else matrix_bot_maubot_version }}"
|
||||
|
||||
# renovate: datasource=docker depName=dock.mau.dev/maubot/maubot
|
||||
@ -26,9 +25,26 @@ matrix_bot_maubot_docker_image: "{{ matrix_bot_maubot_docker_image_name_prefix }
|
||||
matrix_bot_maubot_docker_image_name_prefix: "{{ 'localhost/' if matrix_bot_maubot_container_image_self_build else 'dock.mau.dev/' }}"
|
||||
matrix_bot_maubot_docker_image_force_pull: "{{ matrix_bot_maubot_docker_image.endswith(':latest') }}"
|
||||
|
||||
# matrix_bot_maubot_docker_image_customized is the name of the locally built maubot image
|
||||
# which adds various customizations on top of the original (upstream) maubot image.
|
||||
# This image will be based on the upstream `matrix_bot_maubot_docker_image` image, only if `matrix_bot_maubot_container_image_customizations_enabled: true`.
|
||||
matrix_bot_maubot_docker_image_customized: "localhost/maubot/maubot:{{ matrix_bot_maubot_version }}-customized"
|
||||
|
||||
# Controls whether the customized image (`matrix_bot_maubot_docker_image_customized`) is to be force-built without layer caching enabled.
|
||||
matrix_bot_maubot_docker_image_customized_build_nocache: false
|
||||
|
||||
# Controls whether the customized image (`matrix_bot_maubot_docker_image_customized`) is to be built, even if it already exists.
|
||||
# Related to: matrix_bot_maubot_docker_image_customized_build_nocache
|
||||
matrix_bot_maubot_docker_image_customized_force_source: "{{ matrix_bot_maubot_docker_image_customized_build_nocache }}"
|
||||
|
||||
# matrix_bot_maubot_docker_image_final holds the name of the maubot image to run depending on whether or not customizations are enabled.
|
||||
matrix_bot_maubot_docker_image_final: "{{ matrix_bot_maubot_docker_image_customized if matrix_bot_maubot_container_image_customizations_enabled else matrix_bot_maubot_docker_image }} "
|
||||
|
||||
matrix_bot_maubot_base_path: "{{ matrix_base_data_path }}/maubot"
|
||||
matrix_bot_maubot_data_path: "{{ matrix_bot_maubot_base_path }}/data"
|
||||
matrix_bot_maubot_config_path: "{{ matrix_bot_maubot_base_path }}/config"
|
||||
matrix_bot_maubot_docker_src_files_path: "{{ matrix_bot_maubot_base_path }}/docker-src"
|
||||
matrix_bot_maubot_customized_docker_src_files_path: "{{ matrix_bot_maubot_base_path }}/customized-docker-src"
|
||||
|
||||
matrix_bot_maubot_bot_server_public_url: "{{ matrix_bot_maubot_scheme }}://{{ matrix_bot_maubot_hostname }}"
|
||||
matrix_bot_maubot_bot_server_base_path: "{{ matrix_bot_maubot_path_prefix }}/v1"
|
||||
@ -87,6 +103,30 @@ matrix_bot_maubot_container_additional_networks: "{{ matrix_bot_maubot_container
|
||||
matrix_bot_maubot_container_additional_networks_auto: []
|
||||
matrix_bot_maubot_container_additional_networks_custom: []
|
||||
|
||||
|
||||
# matrix_bot_maubot_container_image_customizations_enabled controls whether a customized maubot image will be built.
|
||||
#
|
||||
# We toggle this variable to `true` when certain features which require a custom build are enabled.
|
||||
# Feel free to toggle this to `true` yourself and specify build steps in `matrix_bot_maubot_container_image_customizations_dockerfile_body_custom`.
|
||||
#
|
||||
# See:
|
||||
# - `roles/custom/matrix-bot-maubot/templates/maubot/customizations/Dockerfile.j2`
|
||||
# - `matrix_bot_maubot_container_image_customizations_dockerfile_body_custom`
|
||||
# - `matrix_bot_maubot_docker_image_customized`
|
||||
# - `matrix_bot_maubot_docker_image_final`
|
||||
matrix_bot_maubot_container_image_customizations_enabled: false
|
||||
|
||||
# matrix_bot_maubot_container_image_customizations_dockerfile_body contains your custom Dockerfile steps
|
||||
# for building your customized maubot image based on the original (upstream) image (`matrix_bot_maubot_docker_image`).
|
||||
# A `FROM …` clause is included automatically so you don't have to.
|
||||
#
|
||||
# Example:
|
||||
# matrix_bot_maubot_container_image_customizations_dockerfile_body_custom: |
|
||||
# RUN echo 'This is a custom step for building the customized container image for maubot.'
|
||||
# RUN echo 'You can override matrix_bot_maubot_container_image_customizations_dockerfile_body_custom to add your own steps.'
|
||||
# RUN echo 'You do NOT need to include a FROM clause yourself.'
|
||||
matrix_bot_maubot_container_image_customizations_dockerfile_body_custom: ''
|
||||
|
||||
# matrix_bot_maubot_container_labels_traefik_enabled controls whether labels to assist a Traefik reverse-proxy will be attached to the container.
|
||||
# See `../templates/labels.j2` for details.
|
||||
#
|
||||
|
Reference in New Issue
Block a user