Code Monkey home page Code Monkey logo

liferay-docker's Introduction

Liferay Community Edition Portal 7.1.3 CE GA4 + JBoss WildFly 11 + Docker

Docker Hub Image (https://hub.docker.com/r/iakim/liferay-docker)

Follow all this steps bellow for create with success your container

Start Docker

Run commands, if necessary, for start your docker service

# mkdir /sys/fs/cgroup/systemd
# mount -t cgroup -o none,name=systemd cgroup /sys/fs/cgroup/systemd
# service docker start

Docker Compose

If you want a liferay from scratch follow this step

# yum install docker-compose
# cd /tmp
# curl "https://raw.githubusercontent.com/Iakim/Liferay-docker/master/docker-compose.yml" -o docker-compose.yml
# docker-compose up --no-start
# docker start tmp_iakimv2_1
# docker start tmp_iakimv1_1

The steps below are for you to transform your liferay installation into a docker container, with themes, modules, database and document library.

Dependencies

The Elasticsearch 6.5.1 is a dependencies and clone this repository

# docker network create liferay
# docker pull docker.elastic.co/elasticsearch/elasticsearch:6.5.1
# docker create --name iakimv2 -p 9200:9200 -p 9300:9300 --network liferay -e "discovery.type=single-node" iakim/elasticsearch-liferay:6.5.1
# docker start iakimv2
# git clone https://github.com/Iakim/Liferay-docker.git
# cd Liferay-docker

Customize your installation

Copy the folders, of your previous instalation, hypersonic and document_library for data

# cp -r /opt/you_instalation_liferay_path/data/hypersonic/* data/hypersonic/
# cp -r /opt/you_instalation_liferay_path/data/document_library/* data/document_library/

Copy your thema for folder DEP/osgi/war/

# cp /opt/you_instalation_liferay_path/osgi/war/my_theme.war DEP/osgi/war/

Copy your modules fot folder DEP/osgi/modules

# cp /opt/you_instalation_liferay_path/osgi/modules/* DEP/osgi/modules/

Update the lportal.script

# sed -i 's/a  \".*:9300\"/a  \"iakimv2:9300\"/' data/hypersonic/lportal.script
# sed -i 's/aclusterName=\".*u000d\\u000ad/aclusterName=\"docker-cluster\"\\u000d\\u000ad/' data/hypersonic/lportal.script

Review portal-ext.properties

# vim portal-ext.properties  

Review standalone.conf

# vim standalone.conf

Checkpoint

Construct your container

Execute the commands bellow to contruct your container

# docker build -t iakim/liferay-docker .
# docker create --name iakimv1 -p 8080:8080 -p 9990:9990 --network liferay  iakim/liferay-docker:latest
# docker start iakimv1
# docker exec -u jboss iakimv1 touch /opt/jboss/wildfly/standalone/deployments/ROOT.war.dodeploy
# docker ps -a

See Logs

JBoss WildFly Logs

# docker logs -f iakimv1

Liferay Logs

# y=`date +%Y`; m=`date +%m`; d=`date +%d`; docker exec -it iakimv1 tail -f /opt/jboss/logs/liferay.$y-$m-$d.log

End Steps

Log in portal http://localhost:8080/c/portal/login

  • User: [email protected]

  • Pass: test

    Control Panel -> Configuration -> Search -> Reindex all indexes of search

Destroy your container and image

Execute the commands bellow to destruct your container and your image

# docker stop iakimv1
# docker rm iakimv1
# docker image rm iakim/liferay-docker:latest

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.