Hide Forgot
Created attachment 811036 [details] jar file Description of problem: When I try to deploy jboss-servlet-security.war to jbossas-7 app, the app gets unavailable and app-restart does not help Version-Release number of selected component (if applicable): OpenShift build N 2.0.34 How reproducible: Always Steps to Reproduce: 1. git clone git:jboss-jdf/jboss-as-quickstart.git 2. cd jboss-as-quickstart/servlet-security 3. mvn build 4. rhc app create myapp jbossas-7 5. touch %app_home%/deployments/jboss-as-xml-dom4j.war.dodeploy 6. cp jboss-as-quickstart/servlet-security/target/jboss-servlet-security.war %app_home%/deployments/ 7. git add. ; git commit -am "test" ; git push Actual results: The app becomes unavailable Expected results: The app is available and you can access %app_url%/jboss-servlet-security Additional info: You need to have a working maven installation and jboss-eap-6.1.1.GA-maven-repository installed in your ~/.m2/ folder. If you don't have it, just use attached jboss-servlet-security.war file
Is this supposed to work? Using the attached WAR file, I see this in server.log: 2013/10/25 14:23:05,775 INFO [org.jboss.as.server] (DeploymentScanner-threads - 2) JBAS015870: Deploy of deployment "jboss-servlet-security.war" was rolled back with failure message {"JBAS014771: Services with missing/unavailable dependencies" => ["jboss.web.deployment.default-host./jboss-servlet-security.realmjboss.security.security-domain.servlet-security-quickstartMissing[jboss.web.deployment.default-host./jboss-servlet-security.realmjboss.security.security-domain.servlet-security-quickstart]"]}
It can work before, but now it is also reproduced on devenv_3958. I have tried to add jboss-as-xml-dom4j.war.dodeploy or jboss-servlet-security.war.dodeploy to %app_home%/deployments/ directory, all they can not work well for now.
you can't deploy this war by itself, it has dependencies on modifications to the jboss standalone.xml (adding a new security domain), as well as adding users to the jboss deployment. did this work previously?
@Ben Parees, It can work previously since I created the related case about on August 2013, and tested it on that time, it work well.
@chunchen: can you provide me w/ the description of the related test case and any necessary artifacts? I'd like to try that test case before revisiting what is described in comment 1.
@Ben Parees, my test case steps are similar with the bug's "Steps to Reproduce", and it does not need extra artifacts, as below: 1. Clone jbossas quickstarts from github git clone https://github.com/jboss-jdf/jboss-as-quickstart.git 2. Go to hibernate3 and mvn build cd jboss-eap-quickstart/servlet-security mvn package 3. Create a jbossas-7 app rhc app create cas00 jbossas-7 4. Copy "jboss-servlet-security.war" to deployments/ dir cd cas00 cp /path/to/jboss-as-quickstart/servlet-security/target/jboss-servlet-security.war ./deployments/ 5. Touch "$war_name.dodeploy" file in deployments/ dir touch ./deployments/jboss-as-servlet-security.war.dodeploy 6. Git push the war package git add .; git commit -amp; git push 7. Port forward this app and access http://127.0.0.1:8080/jboss-servlet-security
I'm not sure how these steps would have worked historically, since the quickstart readme makes it clear that you need to modify your JBoss install to: 1) add a new security domain 2) define the users - Note that I did not actually need to do this second step to get the quickstart to work. It looks like the quickstart was changed in october 2012 to use a custom security domain instead of "other" (which does exist in the default standalone.xml) so that is when I would have expected this test case to have broken... not sure why it would have worked in august unless it was run using an old version of the quickstart files. Following the readme and adapting the instructions for openshift, I was able to make this work. The additional step needed, prior to pushing the war file, are: 1) edit .openshift/config/standalone.xml in the app repo to add the new domain described in the README.md: <security-domains> <security-domain name="servlet-security-quickstart" cache-type="default"> <authentication> <login-module code="Database" flag="required"> <module-option name="dsJndiName" value="java:jboss/datasources/ServletSecurityDS"/> <module-option name="principalsQuery" value="SELECT PASSWORD FROM USERS WHERE USERNAME = ?"/> <module-option name="rolesQuery" value="SELECT R.NAME, 'Roles' FROM USERS_ROLES UR INNER JOIN ROLES R ON R.ID = UR.ROLE_ID INNER JOIN USERS U ON U.ID = UR.USER_ID WHERE U.USERNAME = ?"/> </login-module> </authentication> </security-domain> 3) in your app repo, push the new standalone.xml and war file: git commit -am . ; git push The quickstart will now work as expected.