Skip to content

Instantly share code, notes, and snippets.

@pedroblandim
Last active September 5, 2024 19:42
Show Gist options
  • Save pedroblandim/97dbad26f47fef36ca057c1b45e7755f to your computer and use it in GitHub Desktop.
Save pedroblandim/97dbad26f47fef36ca057c1b45e7755f to your computer and use it in GitHub Desktop.
Liferay docker compose
version: "3.8"
services:
liferay:
image: liferay/portal:7.4.3.19-ga19
container_name: tomcat
networks:
- fs72sp1
depends_on:
- postgres
environment:
LIFERAY_JVM_OPTS: -Xms8g -Xmx8g -agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=8000 -Dcom.sun.management.jmxremote -Dcom.sun.management.jmxremote.port=9010 -Dcom.sun.management.jmxremote.local.only=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.ssl=false
LIFERAY_JDBC_PERIOD_DEFAULT_PERIOD_DRIVER_UPPERCASEC_LASS_UPPERCASEN_AME: org.postgresql.Driver
LIFERAY_JDBC_PERIOD_DEFAULT_PERIOD_URL: "jdbc:postgresql://postgres:5432/simplify?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false"
LIFERAY_JDBC_PERIOD_DEFAULT_PERIOD_USERNAME: postgres
LIFERAY_JDBC_PERIOD_DEFAULT_PERIOD_PASSWORD: postgres
ports:
- 8080:8080
- 8000:8000
- 11311:11311
volumes:
- ./mount:/mnt/liferay
- liferay-data:/opt/liferay/data
- liferay-osgi-configs:/opt/liferay/osgi/configs
- liferay-osgi-marketplace:/opt/liferay/osgi/marketplace
- liferay-osgi-modules:/opt/liferay/osgi/modules
- liferay-osgi-war:/opt/liferay/osgi/war
postgres:
image: postgres:15.1
container_name: postgres
networks:
- fs72sp1
environment:
POSTGRES_PASSWORD: postgres
POSTGRES_USERNAME: postgres
POSTGRES_DB: simplify
ports:
- 5434:5432
volumes:
- pgdata:/var/lib/postgresql/data
networks:
fs72sp1:
name: fs72sp1
volumes:
liferay-data:
liferay-osgi-configs:
liferay-osgi-marketplace:
liferay-osgi-modules:
liferay-osgi-war:
pgdata:
version: "3.8"
services:
liferay:
image: liferay/portal:7.4.3.19-ga19
container_name: tomcat
networks:
- fs72sp1
depends_on:
- elasticsearch
- postgres
environment:
# LIFERAY_RETRY_PERIOD_JDBC_PERIOD_ON_PERIOD_STARTUP_PERIOD_DELAY: 10
# LIFERAY_RETRY_PERIOD_JDBC_PERIOD_ON_PERIOD_STARTUP_PERIOD_MAX_PERIOD_RETRIES: 10
# LIFERAY_JVM_OPTS: "-Xms2560m -Xmx4096m"
LIFERAY_JDBC_PERIOD_DEFAULT_PERIOD_DRIVER_UPPERCASEC_LASS_UPPERCASEN_AME: org.postgresql.Driver
LIFERAY_JDBC_PERIOD_DEFAULT_PERIOD_URL: "jdbc:postgresql://postgres:5432/simplify?useUnicode=true&characterEncoding=UTF-8&useFastDateParsing=false"
LIFERAY_JDBC_PERIOD_DEFAULT_PERIOD_USERNAME: postgres
LIFERAY_JDBC_PERIOD_DEFAULT_PERIOD_PASSWORD: postgres
ports:
- 80:8080
- 443:8443
- 11311:11311
volumes:
- ./mount:/mnt/liferay
- liferay-data:/opt/liferay/data
- liferay-osgi-configs:/opt/liferay/osgi/configs
- liferay-osgi-marketplace:/opt/liferay/osgi/marketplace
- liferay-osgi-modules:/opt/liferay/osgi/modules
- liferay-osgi-war:/opt/liferay/osgi/war
- ./ssl:/opt/liferay/tomcat-9.0.56/ssl
- ./server.xml:/opt/liferay/tomcat/conf/server.xml
- ./server.xml:/opt/liferay/tomcat-9.0.56/conf/server.xml
postgres:
image: postgres:15.1
container_name: postgres
networks:
- fs72sp1
environment:
POSTGRES_PASSWORD: postgres
POSTGRES_USERNAME: postgres
POSTGRES_DB: simplify
ports:
- 5434:5432
volumes:
- pgdata:/var/lib/postgresql/data
elasticsearch:
image: docker.elastic.co/elasticsearch/elasticsearch:7.17.4
container_name: elasticsearch
environment:
ES_JAVA_OPTS: -Xms512m -Xmx512m
discovery.type: single-node
node.name: es-node1
networks:
- fs72sp1
ports:
- 9400:9200
- 9500:9300
ulimits:
memlock:
soft: -1
hard: -1
volumes:
- elasticsearch-data:/usr/share/elasticsearch/data
- elasticsearch-plugins:/usr/share/elasticsearch/plugins
networks:
fs72sp1:
name: fs72sp1
volumes:
elasticsearch-data:
elasticsearch-plugins:
liferay-data:
liferay-osgi-configs:
liferay-osgi-marketplace:
liferay-osgi-modules:
liferay-osgi-war:
pgdata:
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment