[Lift] Re: Symlinks and Javascript Files
I'd advise against using sym links. They don't work on Windows and don't necessarily get JARed/WARed up correctly. On Mon, Aug 17, 2009 at 6:09 PM, Peter Robinett wrote: > > mvn -Dorg.mortbay.util.FileResource.checkAliases=False jetty:run lead > to: > > HTTP ERROR 503 > > Problem accessing /jquery.sparkline.js. Reason: > >java.lang.IllegalStateException: Alias checking disabled > > Is is just for the symlin in the webroot – requsting the one in the js > subdirectory still causes Lift to say it isn't in the SiteMap. > > Any ideas? Thanks? > > Peter > > On Aug 16, 7:13 am, Derek Chen-Becker wrote: > > OK, this is not Lift's error message, but rather Jetty's. You need to set > > the following property to tell Jetty not to check symlinks: > > > > -Dorg.mortbay.util.FileResource.checkAliases=False > > > > Derek > > > > On Fri, Aug 14, 2009 at 1:28 PM, Peter Robinett >wrote: > > > > > > > > > It is not in my site map. I did try the ResourceServer with the > > > symlinked script in the 'js' subdir. > > > > > Peter > > > > > On Aug 14, 6:43 am, Derek Chen-Becker wrote: > > > > Is the path to that file defined in your SiteMap? In the case of > using > > > > ResourceServer, the "js" that you've tried means that the script > should > > > be > > > > under a "js" subdir. > > > > > > Derek > > > > > > On Thu, Aug 13, 2009 at 7:57 PM, Peter Robinett < > pe...@bubblefoundry.com > > > >wrote: > > > > > > > My Lift project is in a git repository and to the repository I've > > > > > added a submodule. Since right now I only want one javascript file > > > > > from this submodule, my thought was to make the directory src/main/ > > > > > webroot/js and then make a symbolic link to the javascript file in > > > > > question. Unfortunately, when I try to request the file at > > > > >http://localhost:9090/js/jquery.sparkline.js, I get a 403 response > > > > > that says the page is not defined in my sitemap. There was no note > of > > > > > the request in the stdout. > > > > > > > Thinking that the js subdirectory is the problem, I then tried > making > > > > > the symlink in the webroot directory and got a 404 error. On stdout > it > > > > > said: > > > > > 2009-08-13 18:38:23.051::WARN: Aliased resource: > file:/Users/peter/ > > > > > Sites/Equal%20Networks/server/src/main/webapp/ > > > > > > jquery.sparkline.js==file:/Users/peter/Sites/Equal%20Networks/server/ > > > > > vendors/dashboard/www/jquery.sparkline.js > > > > > > > From this I gather than Lift is troubled by the presence of a > symlink > > > > > and refused to acknowledge its presence. Is this true? If so, why? > > > > > > > From the thread last week on ExtJS I see a discussion on loading > files > > > > > in webroot, including supporting a css directory by adding the > > > > > following to Boot.scala: > > > > > ResourceServer.allow { > > > > > case "css" :: _ => true > > > > > } > > > > > > > I already have a css file being served from a directory in the > exact > > > > > same location without any additions to Boot.scala. Nonetheless, I > > > > > tried the following: > > > > > ResourceServer.allow { > > > > > case "js" :: _ => true > > > > > } > > > > > > > Unfortunately, this had no effect. So, how can I get my symlinked > > > > > javascript to be server? Or should I just give up on symlinks > > > > > altogether (I'm not a git master, so perhaps that was the wrong > > > > > approach anyway). > > > > > > > Peter Robinett > > > > > > > PS I'm on 1.1-SNAPSHOT. > > > > > PPS The YUI Compressor works well. Very cool. > > > -- Lift, the simply functional web framework http://liftweb.net Beginning Scala http://www.apress.com/book/view/1430219890 Follow me: http://twitter.com/dpp Git some: http://github.com/dpp --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to liftweb@googlegroups.com To unsubscribe from this group, send email to liftweb+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~--~~~~--~~--~--~---
[Lift] Re: Symlinks and Javascript Files
I really don't know enough about Jetty to really say what else is going wrong here, Sorry :( Derek On Mon, Aug 17, 2009 at 7:09 PM, Peter Robinett wrote: > > mvn -Dorg.mortbay.util.FileResource.checkAliases=False jetty:run lead > to: > > HTTP ERROR 503 > > Problem accessing /jquery.sparkline.js. Reason: > >java.lang.IllegalStateException: Alias checking disabled > > Is is just for the symlin in the webroot – requsting the one in the js > subdirectory still causes Lift to say it isn't in the SiteMap. > > Any ideas? Thanks? > > Peter > > On Aug 16, 7:13 am, Derek Chen-Becker wrote: > > OK, this is not Lift's error message, but rather Jetty's. You need to set > > the following property to tell Jetty not to check symlinks: > > > > -Dorg.mortbay.util.FileResource.checkAliases=False > > > > Derek > > > > On Fri, Aug 14, 2009 at 1:28 PM, Peter Robinett >wrote: > > > > > > > > > It is not in my site map. I did try the ResourceServer with the > > > symlinked script in the 'js' subdir. > > > > > Peter > > > > > On Aug 14, 6:43 am, Derek Chen-Becker wrote: > > > > Is the path to that file defined in your SiteMap? In the case of > using > > > > ResourceServer, the "js" that you've tried means that the script > should > > > be > > > > under a "js" subdir. > > > > > > Derek > > > > > > On Thu, Aug 13, 2009 at 7:57 PM, Peter Robinett < > pe...@bubblefoundry.com > > > >wrote: > > > > > > > My Lift project is in a git repository and to the repository I've > > > > > added a submodule. Since right now I only want one javascript file > > > > > from this submodule, my thought was to make the directory src/main/ > > > > > webroot/js and then make a symbolic link to the javascript file in > > > > > question. Unfortunately, when I try to request the file at > > > > >http://localhost:9090/js/jquery.sparkline.js, I get a 403 response > > > > > that says the page is not defined in my sitemap. There was no note > of > > > > > the request in the stdout. > > > > > > > Thinking that the js subdirectory is the problem, I then tried > making > > > > > the symlink in the webroot directory and got a 404 error. On stdout > it > > > > > said: > > > > > 2009-08-13 18:38:23.051::WARN: Aliased resource: > file:/Users/peter/ > > > > > Sites/Equal%20Networks/server/src/main/webapp/ > > > > > > jquery.sparkline.js==file:/Users/peter/Sites/Equal%20Networks/server/ > > > > > vendors/dashboard/www/jquery.sparkline.js > > > > > > > From this I gather than Lift is troubled by the presence of a > symlink > > > > > and refused to acknowledge its presence. Is this true? If so, why? > > > > > > > From the thread last week on ExtJS I see a discussion on loading > files > > > > > in webroot, including supporting a css directory by adding the > > > > > following to Boot.scala: > > > > > ResourceServer.allow { > > > > > case "css" :: _ => true > > > > > } > > > > > > > I already have a css file being served from a directory in the > exact > > > > > same location without any additions to Boot.scala. Nonetheless, I > > > > > tried the following: > > > > > ResourceServer.allow { > > > > > case "js" :: _ => true > > > > > } > > > > > > > Unfortunately, this had no effect. So, how can I get my symlinked > > > > > javascript to be server? Or should I just give up on symlinks > > > > > altogether (I'm not a git master, so perhaps that was the wrong > > > > > approach anyway). > > > > > > > Peter Robinett > > > > > > > PS I'm on 1.1-SNAPSHOT. > > > > > PPS The YUI Compressor works well. Very cool. > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to liftweb@googlegroups.com To unsubscribe from this group, send email to liftweb+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~--~~~~--~~--~--~---
[Lift] Re: Symlinks and Javascript Files
mvn -Dorg.mortbay.util.FileResource.checkAliases=False jetty:run lead to: HTTP ERROR 503 Problem accessing /jquery.sparkline.js. Reason: java.lang.IllegalStateException: Alias checking disabled Is is just for the symlin in the webroot – requsting the one in the js subdirectory still causes Lift to say it isn't in the SiteMap. Any ideas? Thanks? Peter On Aug 16, 7:13 am, Derek Chen-Becker wrote: > OK, this is not Lift's error message, but rather Jetty's. You need to set > the following property to tell Jetty not to check symlinks: > > -Dorg.mortbay.util.FileResource.checkAliases=False > > Derek > > On Fri, Aug 14, 2009 at 1:28 PM, Peter Robinett > wrote: > > > > > It is not in my site map. I did try the ResourceServer with the > > symlinked script in the 'js' subdir. > > > Peter > > > On Aug 14, 6:43 am, Derek Chen-Becker wrote: > > > Is the path to that file defined in your SiteMap? In the case of using > > > ResourceServer, the "js" that you've tried means that the script should > > be > > > under a "js" subdir. > > > > Derek > > > > On Thu, Aug 13, 2009 at 7:57 PM, Peter Robinett > >wrote: > > > > > My Lift project is in a git repository and to the repository I've > > > > added a submodule. Since right now I only want one javascript file > > > > from this submodule, my thought was to make the directory src/main/ > > > > webroot/js and then make a symbolic link to the javascript file in > > > > question. Unfortunately, when I try to request the file at > > > >http://localhost:9090/js/jquery.sparkline.js, I get a 403 response > > > > that says the page is not defined in my sitemap. There was no note of > > > > the request in the stdout. > > > > > Thinking that the js subdirectory is the problem, I then tried making > > > > the symlink in the webroot directory and got a 404 error. On stdout it > > > > said: > > > > 2009-08-13 18:38:23.051::WARN: Aliased resource: file:/Users/peter/ > > > > Sites/Equal%20Networks/server/src/main/webapp/ > > > > jquery.sparkline.js==file:/Users/peter/Sites/Equal%20Networks/server/ > > > > vendors/dashboard/www/jquery.sparkline.js > > > > > From this I gather than Lift is troubled by the presence of a symlink > > > > and refused to acknowledge its presence. Is this true? If so, why? > > > > > From the thread last week on ExtJS I see a discussion on loading files > > > > in webroot, including supporting a css directory by adding the > > > > following to Boot.scala: > > > > ResourceServer.allow { > > > > case "css" :: _ => true > > > > } > > > > > I already have a css file being served from a directory in the exact > > > > same location without any additions to Boot.scala. Nonetheless, I > > > > tried the following: > > > > ResourceServer.allow { > > > > case "js" :: _ => true > > > > } > > > > > Unfortunately, this had no effect. So, how can I get my symlinked > > > > javascript to be server? Or should I just give up on symlinks > > > > altogether (I'm not a git master, so perhaps that was the wrong > > > > approach anyway). > > > > > Peter Robinett > > > > > PS I'm on 1.1-SNAPSHOT. > > > > PPS The YUI Compressor works well. Very cool. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to liftweb@googlegroups.com To unsubscribe from this group, send email to liftweb+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~--~~~~--~~--~--~---
[Lift] Re: Symlinks and Javascript Files
OK, this is not Lift's error message, but rather Jetty's. You need to set the following property to tell Jetty not to check symlinks: -Dorg.mortbay.util.FileResource.checkAliases=False Derek On Fri, Aug 14, 2009 at 1:28 PM, Peter Robinett wrote: > > It is not in my site map. I did try the ResourceServer with the > symlinked script in the 'js' subdir. > > Peter > > On Aug 14, 6:43 am, Derek Chen-Becker wrote: > > Is the path to that file defined in your SiteMap? In the case of using > > ResourceServer, the "js" that you've tried means that the script should > be > > under a "js" subdir. > > > > Derek > > > > On Thu, Aug 13, 2009 at 7:57 PM, Peter Robinett >wrote: > > > > > > > > > My Lift project is in a git repository and to the repository I've > > > added a submodule. Since right now I only want one javascript file > > > from this submodule, my thought was to make the directory src/main/ > > > webroot/js and then make a symbolic link to the javascript file in > > > question. Unfortunately, when I try to request the file at > > >http://localhost:9090/js/jquery.sparkline.js, I get a 403 response > > > that says the page is not defined in my sitemap. There was no note of > > > the request in the stdout. > > > > > Thinking that the js subdirectory is the problem, I then tried making > > > the symlink in the webroot directory and got a 404 error. On stdout it > > > said: > > > 2009-08-13 18:38:23.051::WARN: Aliased resource: file:/Users/peter/ > > > Sites/Equal%20Networks/server/src/main/webapp/ > > > jquery.sparkline.js==file:/Users/peter/Sites/Equal%20Networks/server/ > > > vendors/dashboard/www/jquery.sparkline.js > > > > > From this I gather than Lift is troubled by the presence of a symlink > > > and refused to acknowledge its presence. Is this true? If so, why? > > > > > From the thread last week on ExtJS I see a discussion on loading files > > > in webroot, including supporting a css directory by adding the > > > following to Boot.scala: > > > ResourceServer.allow { > > > case "css" :: _ => true > > > } > > > > > I already have a css file being served from a directory in the exact > > > same location without any additions to Boot.scala. Nonetheless, I > > > tried the following: > > > ResourceServer.allow { > > > case "js" :: _ => true > > > } > > > > > Unfortunately, this had no effect. So, how can I get my symlinked > > > javascript to be server? Or should I just give up on symlinks > > > altogether (I'm not a git master, so perhaps that was the wrong > > > approach anyway). > > > > > Peter Robinett > > > > > PS I'm on 1.1-SNAPSHOT. > > > PPS The YUI Compressor works well. Very cool. > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to liftweb@googlegroups.com To unsubscribe from this group, send email to liftweb+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~--~~~~--~~--~--~---
[Lift] Re: Symlinks and Javascript Files
It is not in my site map. I did try the ResourceServer with the symlinked script in the 'js' subdir. Peter On Aug 14, 6:43 am, Derek Chen-Becker wrote: > Is the path to that file defined in your SiteMap? In the case of using > ResourceServer, the "js" that you've tried means that the script should be > under a "js" subdir. > > Derek > > On Thu, Aug 13, 2009 at 7:57 PM, Peter Robinett > wrote: > > > > > My Lift project is in a git repository and to the repository I've > > added a submodule. Since right now I only want one javascript file > > from this submodule, my thought was to make the directory src/main/ > > webroot/js and then make a symbolic link to the javascript file in > > question. Unfortunately, when I try to request the file at > >http://localhost:9090/js/jquery.sparkline.js, I get a 403 response > > that says the page is not defined in my sitemap. There was no note of > > the request in the stdout. > > > Thinking that the js subdirectory is the problem, I then tried making > > the symlink in the webroot directory and got a 404 error. On stdout it > > said: > > 2009-08-13 18:38:23.051::WARN: Aliased resource: file:/Users/peter/ > > Sites/Equal%20Networks/server/src/main/webapp/ > > jquery.sparkline.js==file:/Users/peter/Sites/Equal%20Networks/server/ > > vendors/dashboard/www/jquery.sparkline.js > > > From this I gather than Lift is troubled by the presence of a symlink > > and refused to acknowledge its presence. Is this true? If so, why? > > > From the thread last week on ExtJS I see a discussion on loading files > > in webroot, including supporting a css directory by adding the > > following to Boot.scala: > > ResourceServer.allow { > > case "css" :: _ => true > > } > > > I already have a css file being served from a directory in the exact > > same location without any additions to Boot.scala. Nonetheless, I > > tried the following: > > ResourceServer.allow { > > case "js" :: _ => true > > } > > > Unfortunately, this had no effect. So, how can I get my symlinked > > javascript to be server? Or should I just give up on symlinks > > altogether (I'm not a git master, so perhaps that was the wrong > > approach anyway). > > > Peter Robinett > > > PS I'm on 1.1-SNAPSHOT. > > PPS The YUI Compressor works well. Very cool. --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to liftweb@googlegroups.com To unsubscribe from this group, send email to liftweb+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~--~~~~--~~--~--~---
[Lift] Re: Symlinks and Javascript Files
Is the path to that file defined in your SiteMap? In the case of using ResourceServer, the "js" that you've tried means that the script should be under a "js" subdir. Derek On Thu, Aug 13, 2009 at 7:57 PM, Peter Robinett wrote: > > My Lift project is in a git repository and to the repository I've > added a submodule. Since right now I only want one javascript file > from this submodule, my thought was to make the directory src/main/ > webroot/js and then make a symbolic link to the javascript file in > question. Unfortunately, when I try to request the file at > http://localhost:9090/js/jquery.sparkline.js, I get a 403 response > that says the page is not defined in my sitemap. There was no note of > the request in the stdout. > > Thinking that the js subdirectory is the problem, I then tried making > the symlink in the webroot directory and got a 404 error. On stdout it > said: > 2009-08-13 18:38:23.051::WARN: Aliased resource: file:/Users/peter/ > Sites/Equal%20Networks/server/src/main/webapp/ > jquery.sparkline.js==file:/Users/peter/Sites/Equal%20Networks/server/ > vendors/dashboard/www/jquery.sparkline.js > > From this I gather than Lift is troubled by the presence of a symlink > and refused to acknowledge its presence. Is this true? If so, why? > > From the thread last week on ExtJS I see a discussion on loading files > in webroot, including supporting a css directory by adding the > following to Boot.scala: > ResourceServer.allow { > case "css" :: _ => true > } > > I already have a css file being served from a directory in the exact > same location without any additions to Boot.scala. Nonetheless, I > tried the following: > ResourceServer.allow { > case "js" :: _ => true > } > > Unfortunately, this had no effect. So, how can I get my symlinked > javascript to be server? Or should I just give up on symlinks > altogether (I'm not a git master, so perhaps that was the wrong > approach anyway). > > Peter Robinett > > PS I'm on 1.1-SNAPSHOT. > PPS The YUI Compressor works well. Very cool. > > > --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Lift" group. To post to this group, send email to liftweb@googlegroups.com To unsubscribe from this group, send email to liftweb+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/liftweb?hl=en -~--~~~~--~~--~--~---