Reputation: 2823
I am trying to deploy a *.war file to OpenShift.
After looking at OpenShift documentation, I found a way to deploy binaries to OpenSHift:
rhc deploy path_to_binary -a application_name
However, deploying a simple *.war file fails with the following message:
Error message: Unable to extract deployment archive using command: /bin/tar -xz
It looks like OpenShift requires the binary to be packaged as a tar.gz archive.
So, my question is:
What is the structure of the *.tar.gz, which I can deploy to OpenShift?
Strange, but I was not able to find this info in the documentation.
Upvotes: 2
Views: 1391
Reputation: 351
For a jbossas application, create a tar.gz file with the following contents:
build_dependencies/ (empty directory)
dependencies/jbossas/deployments/ROOT.war
repo/ (empty directory, or you can include .openshift/... if you need hooks or markers)
or for jbosseap:
build_dependencies/ (empty directory)
dependencies/jbosseap/deployments/ROOT.war
repo/ (empty directory, or you can include .openshift/... if you need hooks or markers)
or for jbossews:
build_dependencies/ (empty directory)
dependencies/jbossews/webapps/ROOT.war
repo/ (empty directory, or you can include .openshift/... if you need hooks or markers)
Upvotes: 5
Reputation: 49
If you want to deploy your WAR file (that you build locally) to Open Shift here are the steps.
Your app should run under: your-app-domain.rhcloud.com/yourApp
To delete/undeploy your app, just SSH into your account and delete the file.
Upvotes: 2