lundegaard / lundegaard/react-union
H2 make the content-portlet available into the official Liferay Docker container
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 96
- Forks
- 13
- PR merge metrics
- No merged PRs in 30d
Description
I am a React developer new to Liferay. I am trying to use your Union project to plug my react apps inside a legacy Liferay portal.
I have built a JAR `eu.reactunion.boilerplate.content-portlet-1.0.0.jar` following your instructions at https://react-union.org/boilerplates-liferay#7-build-and-deploy-code-classlanguage-texthero-portletcode-module
Now I am trying to make that JAR available to a running Liferay server.
I am using the official Docker container distribution https://hub.docker.com/r/liferay/portal/
My Dockerfile is the following:
FROM liferay/portal:7.2.0-ga1
COPY --chown=liferay:liferay ./deploy /etc/liferay/mount/deploy
EXPOSE 8080
The folder ./deploy on my PC contains the JAR produced by your scripts, which is correctly copied on the container.
As soon as I run the container, I get the following error message:
org.osgi.framework.BundleException: Could not resolve module: eu.reactunion.boilerplate.content-portlet [1072]_ Unresolved requirement: Import-Package: com.liferay.portal.kernel.portlet; version="[7.0.0,8.0.0)"_ [Sanitized]
at org.eclipse.osgi.container.Module.start(Module.java:444)
at org.eclipse.osgi.internal.framework.EquinoxBundle.start(EquinoxBundle.java:428)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundle(DirectoryWatcher.java:1264)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.startBundles(DirectoryWatcher.java:1237)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.doProcess(DirectoryWatcher.java:520)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.process(DirectoryWatcher.java:365)
at org.apache.felix.fileinstall.internal.DirectoryWatcher.run(DirectoryWatcher.java:316)
My understanding is that Liferay tries to unbundle and launch the JAR, but that dependencies are missing.
Can you please assist me in this issue?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the supplied Dockerfile, the deploy directory, and the Liferay startup stack trace showing the unresolved com.liferay.portal.kernel.portlet import. Reproduce the deployment against liferay/portal:7.2.0-ga1 and determine what configuration or packaging is required; done means the content-portlet starts without the unresolved dependency error.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- docker, java, javascript, react
- Domain
- backend, devops, infrastructure
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100