Jump to content

Recommended Posts

Posted

Hi, I posted an answer her link

 

I'm aware that if this configuration file is wrong every tomcat host instance (every single Tomcat user) will fail, and their website will not be available untill the server.xml is fixed.

 

But, each user should be able to configure at least his host to improve functionalities and performances :

 

-Pure Tomcat SSL configuration

-War root path url

-connection pool

...

 

So you cannot let anyone edit this file manually, you can't edit it each time an user need it, and we need to configure it when we need it...

 

So as a request I created my own thread, is this possible to create a link in the panel with a simple form.

This form will send xml lines, and the server will put those line in the user host inside the server.xml ?

 

I know you have a lot of things to do, that's why I may be able to help you and send you my work if you can tell me in wich language I need to dev that.

 

We really need this :unsure:

Thank you

Posted

 

  

Hello Krydos :)  

 

That's not for now because I don't know how I'll configure my database inside  Tommy... But  as an example (green text will change) for the pool and some other details i'll need to modify this part : 

<Host appBase="webapps" autoDeploy="true" name="www.claod.com" unpackWARs="true">

    <Valve className="org.apache.catalina.valves.AccessLogValve" directory="logs" pattern="%h %l %u %t "%r" %s %b" prefix="localhost_access_log" suffix=".txt"/>
    <Context docBase="claod" path="/" reloadable="true" source="org.eclipse.jst.jee.server:claod">
        <Resource auth="Container" connectionProperties="verifyServerCertificate=true;useSSL=true;requireSSL=true;" defaultAutoCommit="false" driverClassName="com.mysql.jdbc.Driver" initialSize="5" logAbandoned="true" maxIdle="15" maxTotal="100" maxWaitMillis="60000" minIdle="2" name="jdbc/blogdb" password="thepasswordhere" removeAbandonedOnBorrow="true" removeAbandonedTimeout="300" type="javax.sql.DataSource" url="jdbc:mysql://pathto:000/theDatabase" username="TheUserNameHere"/>
    </Context>
</Host>

- After enabling SSL in my web.xml I may need (I do not remember if this part is correct) to change the port of the <connector> tag when I'll get my certificate to force the port 443 replacing the 80.

 

- And the Tomcat server is able to link my .war to my "http(s)://www.claod.heliohost.org/"     -  ( website root ). Without any redirection, index.html +  javascript, htaccess etc...

 

I think I'll name my war "claod_project.war"

 

XML nodes are editable objects in java ( many other languages can do this )... Those nodes are easily identifiable using their properties and their values.

 

What do you think, is this possible to build an UI to change that ? Or do you want me to wait and come in the future to ask your to change those values ? :unsure:

 

Thank you again ^_^

Posted

The server.xml is automatically created/edited. Changing it manually could easily break it for everyone else. What exactly are you trying to do?

Posted

I just want to be able to deploy any .war file or configure anything without any external help.

 

Java is active on my account.

The www/test.jsp was diplaying its scriptlet <%= (so I guess it's not working)

I uploaded my claod_project.war file (as a test) (I'm aware about the http://wiki.helionet.org/Java_Servlet and I know muy project got the wrong versions but i made that project a long time before my inscription here : Tomcat 9, Java 1.8)

I pressed the deploy button... nothing happened

 

When you say "server.xml" automatically created and edited where can I find the option to configure my connection pool in the cpanel ?

 

I know the "server.xml" is shared between all users using Java on Tommy. But the virtual host and some connector tags are a part of claod.heliohist.org. As user I'm not able to configure those options through the cpanel, I need to create a new post each time and disturb you... 

 

Thank you for the time you spend for us  :unsure:

Posted

You're the only one seeing this x) I got a 404

This url with /project/ is not in my web.xml... the problem is that my war file represents my whole site, so I should be able to access it straight from http://claod.heliohost.org/ as I did in my localhost.

Posted (edited)

Hi,

 

I don't understand why it should be any conflict deploying a java project and accessing it straight from http://claod.heliohost.org/

Php servers can do it without any problem with its www folder

 

That's why we can see cgi-bin and we can access an index.html.

3 conflicts are possible : War files names (depends on user name wich unique), Configuration (configurable), and url (depends on domain name chosen by the user, unique per host also)

 

So even if we say it may be conflicts for the names of the files inside the server so we need to use specifics names for the war file : it cannot be ROOT.war the server.xml configuration can load a specific war for a docbase path (the root of the site).

One way :

"Deploy your war as (from your example) war_name.war and configure the context root in conf/server.xml to use your war file :

<Context path="" docBase="war_name" debug="0" reloadable="true"></Context>"

You cannot have more than one ROOT.war inside the same directory on a server okey, but every virtual host got its own url, so no one but me owns claod.heliohost.net. That's why the server.xml virtual host is important for us to configure specificly.

 

The docbase represents the root url of the site on the browser... Each virtual host can access its root this way.

I'm sure there is a way to do so. Even with a single Tomcat server I can deploy multiples .war files with many localhost url, one of them is the localhost root.

 

I think I need to understand were is the problem, I really hope my posts are understandable  :unsure: 

Edited by claod
Posted (edited)

I saw some post about the server.xml, not just mine.

I know you're providing tomcat for 10 years old. I know it's free. Does it mean that your team, and users can't improve this project ?

 

I don't know how you manage users url in your server, that's my lack. I know there is only one ROOT directory per tomcat server. But if you can configure a custom url for each user, the config can be changed to reach our project straight from http://www.userdomain.heliohost.org/

 

There is many way to do so :

http://www.baeldung.com/tomcat-root-application

* https://stackoverflow.com/questions/30750778/run-tomcat-application-from-any-subdomain-subfolder-or-root

 

To deal with conflicts, and link  the user .war project to its root domain path the subdomains conf / server.xml / global conf can help, it's possible.

 

Now if you tell me you're not interested on how it can be done, if you don't want this feature for the community, or if you don't want to discuss about it anymore because you think one of us is angry (I'm not) then so be it...

 

You'll keep losing some java users using the "free + http heliohost vps partners url" method... That sounds sad for me.
I was dreaming about a free host for a long time, now the next step would be to improve it to fit users needs.

Don't think I'm critisizing your work, because I'm not, I feel involved and I want to help, there is a big difference  ;)

 

Thank you again for your patience and your job, have a nice day.

Edited by claod

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...