Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

deployment scanner: .../deployments is not writable #37

Closed
javadan opened this issue Feb 24, 2016 · 3 comments
Closed

deployment scanner: .../deployments is not writable #37

javadan opened this issue Feb 24, 2016 · 3 comments

Comments

@javadan
Copy link

javadan commented Feb 24, 2016

Hi...

This is pretty close to Wildfly - EAP 6.3 - I figured a dev here might be able to help?

I saw a few of this permission issue already - (eg here and here)

but none of the solutions are helping any. I first tried mapping the deployments directory:

*-v /opt/deployments:/opt/jboss/jboss-eap-6.3/standalone/deployments/:rw *

so I could keep the ears/wars on my host, then tried adding the ears into the docker...

ADD someearfile.ear /opt/jboss/jboss-eap-6.3/standalone/deployments/

No matter what, I keep getting
java.lang.IllegalArgumentException: JBAS015054: /opt/jboss/jboss-eap-6.3/standalone/deployments is not writable

Here is my Dockerfile... any ideas?
Regards
Daniel


FROM jboss/base-jdk:7

ADD installs/jboss-eap-6.3.0.zip /tmp/jboss-eap-6.3.0.zip
RUN unzip /tmp/jboss-eap-6.3.0.zip

## allow custom external configuration
ADD standalone-custom.xml /opt/jboss/jboss-eap-6.3/standalone/configuration/

### Set Environment
ENV JBOSS_HOME /opt/jboss/jboss-eap-6.3

### Create EAP User
RUN $JBOSS_HOME/bin/add-user.sh jboss mypassword --silent

USER root
RUN chmod 755 /opt/jboss/jboss-eap-6.3/standalone/deployments/*
RUN chown jboss:jboss /opt/jboss/jboss-eap-6.3/standalone/deployments/*
ADD myear.ear /opt/jboss/jboss-eap-6.3/standalone/deployments/
USER jboss

### Configure EAP
RUN echo "JAVA_OPTS=\"\$JAVA_OPTS -Djboss.bind.address=0.0.0.0 -Djboss.bind.address.management=0.0.0.0\""  >> $JBOSS_HOME/bin/standalone.conf

### Open Ports
EXPOSE 8080 9990 9999

### Start EAP
##  ENTRYPOINT $JBOSS_HOME/bin/standalone.sh -c standalone.xml

CMD ["/opt/jboss/jboss-eap-6.3/bin/standalone.sh", "-c", "standalone-custom.xml", "-b", "0.0.0.0", "-bmanagement", "0.0.0.0"]

@goldmann
Copy link
Contributor

This may help: https://goldmann.pl/blog/2014/07/18/logging-with-the-wildfly-docker-image/#_mounting_a_volume_from_the_host It's an old blog post, but highlights the issue. There is one difference - the current jboss user has ID 1000 and not 433.

@javadan
Copy link
Author

javadan commented Feb 24, 2016

Eh right... ok I removed USER jboss and it got past that. Pretty obvious now. Thanks

@goldmann
Copy link
Contributor

Np :) I'll close this issue now since this is not an issue in the image itself.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants