mirror of
https://github.com/kevinveenbirkenbach/computer-playbook.git
synced 2025-09-24 11:06:24 +02:00
- Added OIDC and LDAP feature flags in config - Introduced API/Console URL vars for proxy alignment - Implemented automatic MinIO policy creation for OIDC admin group - Replaced static env.J2 with dynamic env.j2 (OIDC-aware) - Added policy.json.j2 template with full admin rights - Cleaned up tasks to use stdin instead of file for mc policy apply Ref: https://chatgpt.com/share/68d1d3ef-ca84-800f-abe2-11ab70e20c4e
41 lines
1.2 KiB
YAML
41 lines
1.2 KiB
YAML
---
|
|
- name: "Install Ollama Dependency"
|
|
include_role:
|
|
name: svc-ai-ollama
|
|
vars:
|
|
flush_handlers: true
|
|
when:
|
|
- run_once_svc_ai_ollama is not defined
|
|
- OLLAMA_LOCAL_ENABLED | bool
|
|
|
|
- name: "load docker and db for {{ application_id }}"
|
|
include_role:
|
|
name: sys-stk-back-stateless
|
|
vars:
|
|
docker_compose_flush_handlers: true
|
|
|
|
- name: "Include role sys-stk-front-proxy for each UI domain"
|
|
include_role:
|
|
name: sys-stk-front-proxy
|
|
vars:
|
|
domain: "{{ item.domain }}"
|
|
http_port: "{{ item.http_port }}"
|
|
loop: "{{ MINIO_FRONT_PROXY_MATRIX }}"
|
|
loop_control:
|
|
label: "{{ item.domain }} -> {{ item.http_port }}"
|
|
|
|
- block:
|
|
- name: "Render MinIO policy into variable"
|
|
set_fact:
|
|
minio_policy_content: "{{ lookup('template', 'policy.json.j2') }}"
|
|
|
|
- name: "Apply MinIO policy {{ MINIO_OIDC_POLICY_NAME }}"
|
|
shell: |
|
|
set -euo pipefail
|
|
mc alias set minio {{ MINIO_API_URL }} {{ users.administrator.username }} {{ users.administrator.password }}
|
|
mc admin policy create minio {{ MINIO_OIDC_POLICY_NAME }} /dev/stdin || true
|
|
args:
|
|
executable: /bin/bash
|
|
stdin: "{{ minio_policy_content }}"
|
|
when: MINIO_OIDC_ENABLED | bool
|