feat(dev): external Keycloak detection, scoped services, pytest compatibility
This commit is contained in:
parent
4a021a5711
commit
74a34f453a
19
Makefile
19
Makefile
|
|
@ -1,6 +1,16 @@
|
||||||
# Root Makefile for CMMC-Platform local dev
|
# Root Makefile for CMMC-Platform local dev
|
||||||
|
|
||||||
|
############################################################
|
||||||
|
# Load .env into Make's environment (must be first!)
|
||||||
|
############################################################
|
||||||
|
ifneq (,$(wildcard .env))
|
||||||
|
include .env
|
||||||
|
export $(shell sed -E 's/#.*//' .env | cut -d= -f1)
|
||||||
|
endif
|
||||||
|
|
||||||
|
# ───────────── rest of your Makefile below ─────────────
|
||||||
compose = podman-compose -f dev-compose.yaml
|
compose = podman-compose -f dev-compose.yaml
|
||||||
|
#
|
||||||
|
|
||||||
# ----------------------------------------------------------
|
# ----------------------------------------------------------
|
||||||
# Helpers
|
# Helpers
|
||||||
|
|
@ -11,9 +21,12 @@ create-proxy-net:
|
||||||
# probe external Keycloak once and cache the flag
|
# probe external Keycloak once and cache the flag
|
||||||
check-idp:
|
check-idp:
|
||||||
@echo "🔍 Probing $(KEYCLOAK_URL) for existing Keycloak..."
|
@echo "🔍 Probing $(KEYCLOAK_URL) for existing Keycloak..."
|
||||||
@if curl -sf "${KEYCLOAK_URL:-http://keycloak.local:8080}/realms/master" >/dev/null ; \
|
@if curl -skL --max-time 5 "$${KEYCLOAK_URL:-http://keycloak.local:8080}/realms/master" >/dev/null ; then \
|
||||||
then echo "🥳 External Keycloak detected!"; echo 1 >.idp_flag ; \
|
echo "🥳 External Keycloak detected!"; echo 1 >.idp_flag ; \
|
||||||
else echo "🛠 No external Keycloak found."; echo 0 >.idp_flag ; fi
|
else \
|
||||||
|
echo "🛠 No external Keycloak found."; echo 0 >.idp_flag ; \
|
||||||
|
fi
|
||||||
|
|
||||||
|
|
||||||
# ----------------------------------------------------------
|
# ----------------------------------------------------------
|
||||||
# Lifecycle targets
|
# Lifecycle targets
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue