version: "3.9" networks: rornet: ipam: config: - subnet: "172.25.0.0/16" gateway: "172.25.0.1" volumes: kopano: gitea: mysql: services: kopano: build: ./config/kopano image: custom/kopano container_name: kopano restart: unless-stopped volumes: - kopano:/var/lib/kopano/attachments networks: - rornet hostname: smtp.example.net environment: - TZ=Asia/Tokyo - MYDOMAIN=example.net - KOPANOADMUSER=webmaster - KOPANOADMPASS=webmaster - SERVER_MYSQL_HOST=db - SERVER_MYSQL_USER=rordb - SERVER_MYSQL_PASSWORD=rordb ports: - 8080:80 - 25:25 - 143:143 - 465:465 - 587:587 depends_on: - db gitea: build: ./config/gitea image: custom/gitea container_name: gitea environment: - USER_UID=1000 - USER_GID=1000 - GITEA__database__DB_TYPE=mysql - GITEA__database__HOST=db:3306 - GITEA__database__NAME=gitea - GITEA__database__USER=rordb - GITEA__database__PASSWD=rordb restart: unless-stopped networks: - rornet volumes: - gitea:/data - /etc/timezone:/etc/timezone:ro - /etc/localtime:/etc/localtime:ro - /home/git/.ssh:/data/git/.ssh - ./config/gitea/conf:/data/gitea/conf ports: - 3001:3000 - 127.0.0.1:2222:22 depends_on: - db db: image: mariadb:10.8.3-jammy container_name: rordb restart: unless-stopped command: --transaction-isolation=READ-COMMITTED --binlog-format=ROW volumes: - mysql:/var/lib/mysql - ./config/mariadb-init:/docker-entrypoint-initdb.d networks: - rornet environment: - TZ=Asia/Tokyo - MYSQL_ROOT_PASSWORD=rordb - MYSQL_USER=rordb #config/mariadb-init/init.sqlも一緒に変更 - MYSQL_PASSWORD=rordb