You have a few choices. All outlined in this answer -> http://stackoverflow.com/questions/19232182/jetty-starts-in-c-temp/19232771#19232771
-- Joakim Erdfelt <[email protected]> webtide.com <http://www.webtide.com/> - intalio.com/jetty Expert advice, services and support from from the Jetty & CometD experts eclipse.org/jetty - cometd.org On Tue, Jan 21, 2014 at 5:49 AM, Zen Zhong <[email protected]> wrote: > Hi, Jan > > I mean the extracted webapp.war, it should be extracted by jetty before > it's started, if I set TEMPDIR after it's started, it should not work. > > I did a test, set it in MyServletContextListener.contextInitialized: > sce.getServletContext().setAttribute(ServletContext.TEMPDIR, new > File(path)); > It doesn't work, extracted dir is > /tmp/jetty-0.0.0.0-8080-chatdemo.war-_chatdemo-any-2635942716179691302.dir > > Or do you mean a parameter of jetty? > > Thanks > > > 2014/1/21 Jan Bartel <[email protected]> > >> Hi, >> >> You can configure the temp dir for your webapps using >> wepappcontext.settempdir method (forgive poor camel case, I'm typing this >> on my mobile). >> >> Regards, >> Jan >> On 21/01/2014 4:50 PM, "Zen Zhong" <[email protected]> wrote: >> >>> Hi, >>> >>> On our staging environment (CentOS 6, jetty-9.1.0), I found this issue >>> before and I set up auditd, and this time, I found the command deleted the >>> important files, it's tmpwatch. I've added "-X '/tmp/jetty*'" in >>> /etc/cron.daily/tmpwatch as a workaround for now. >>> >>> Maybe it's better to put webapp temp dir in ${jetty.home}. >>> >>> Thanks >>> >>> _______________________________________________ >>> jetty-users mailing list >>> [email protected] >>> https://dev.eclipse.org/mailman/listinfo/jetty-users >>> >>> >> _______________________________________________ >> jetty-users mailing list >> [email protected] >> https://dev.eclipse.org/mailman/listinfo/jetty-users >> >> > > _______________________________________________ > jetty-users mailing list > [email protected] > https://dev.eclipse.org/mailman/listinfo/jetty-users > >
_______________________________________________ jetty-users mailing list [email protected] https://dev.eclipse.org/mailman/listinfo/jetty-users
