diff --git a/keycloak/README.md b/keycloak/README.md new file mode 100644 index 0000000..5eaab3f --- /dev/null +++ b/keycloak/README.md @@ -0,0 +1 @@ +docker stack deploy -c keycloak.yml keycloak diff --git a/keycloak/keycloak.yml b/keycloak/keycloak.yml new file mode 100644 index 0000000..5e69971 --- /dev/null +++ b/keycloak/keycloak.yml @@ -0,0 +1,38 @@ +version: '3.8' + +services: + keycloak: + image: quay.io/keycloak/keycloak:latest + command: start --optimized + environment: + KC_DB: postgres + KC_DB_URL: jdbc:postgresql://postgres-db:5432/keycloak + KC_DB_USERNAME: postgres + KC_DB_PASSWORD: 98836 + KC_HOSTNAME: auth.emrekirman.com # Kendi domaininizle değiştirin + KC_PROXY: edge # Reverse proxy (Nginx/Traefik) arkasındaysanız gerekli + KEYCLOAK_ADMIN: admin + KEYCLOAK_ADMIN_PASSWORD: eE24619840420* + ports: + - target: 8080 + published: 8080 + protocol: tcp + mode: host + networks: + - postgres_network + - keycloak-net + deploy: + replicas: 2 + update_config: + parallelism: 1 + delay: 10s + restart_policy: + condition: on-failure + +volumes: + postgres_data: +networks: + postgres_network: + external: true + keycloak-net: + external: true \ No newline at end of file