質問

Currently trying to setup multiple subdomains/domains in my Tomcat and I'm needing them all to use the same WEB-INF/classes/ for everything.

Basically my folder structure is like so:

Z:/
project/
    assets/   (assets.domain.com)
    main/     (www.domain.com)
    dev/      (dev.domain.com)
    WEB-INF/  (the WEB-INF I want everyone using.)
        classes/
            com/
                example/

So basically I need assets.domain.com, www.domain.com, and dev.domain.com to go up one level in the directory to find the WEB-INF and use the Java classes stored there... Is there any way to accomplish this? Thanks!

役に立ちましたか?

解決

if you are trying to share java code across webapps, you will need to package them as jar and place it in either server/lib or endorsed folder . then each deployed webapp will have access to the same class files.

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top