version: "3.9"
services:
  wildfly:
    image: wildfly-admin
    container_name: wildfly-admin
    ports:
      - "9990:9990"
    depends_on:
      - openldap
  openldap:
    image: osixia/openldap:1.5.0
    container_name: openldap
    environment:
      LDAP_ORGANISATION: "WildFly"
      LDAP_DOMAIN: "wildfly.org"
      LDAP_BASE_DN: "dc=wildfly,dc=org"
      LDAP_ADMIN_PASSWORD: "admin"
      LDAP_TLS: "false"
      LDAP_REPLICATION: "false"
    volumes:
      - ./bootstrap.ldif:/container/service/slapd/assets/config/bootstrap/ldif/50-bootstrap.ldif
    ports:
      - "389:389"
      - "636:636"
    command: ["--copy-service"]
  phpldapadmin:
    image: osixia/phpldapadmin:latest
    container_name: phpldapadmin
    environment:
      PHPLDAPADMIN_LDAP_HOSTS: "openldap"
      PHPLDAPADMIN_HTTPS: "false"
    ports:
      - "8080:80"
    depends_on:
      - openldap
    command: ["--copy-service"]
