[racket] Simple webserver question
Here's a version that does what I think you want, with comments:
https://gist.github.com/3050866
Jay
On Wed, Jul 4, 2012 at 10:34 PM, Matt Jadud <jadudm at gmail.com> wrote:
> Hi all,
>
> I'm trying to 1) serve static files from a directory relative to my
> script and 2) handle a single POST of some JSON. My goal is to be able
> to compile/share this when I'm done. I'd ideally like to be able to
> control the port, choose whether a browser is opened, and control the
> endpoint for the static content and servlet.
>
> https://gist.github.com/3050679
>
> I've experimented with insta, servlet-env, and dispatch, but am most
> definitely missing something. Old examples around the web predate the
> current state of the libraries, so I'm fairly certain I don't need to
> touch a configuration table or anything else of the sort. It seems
> like #:extra-files-paths or #:server-root-path should be my friend,
> but I'm clearly not doing the right thing.
>
> At this point, I figured someone on the list might be able to quickly
> and easily point me in the right direction... because I'm sure I am
> making this harder than it should be.
>
> Many thanks,
> Matt
> ____________________
> Racket Users list:
> http://lists.racket-lang.org/users
--
Jay McCarthy <jay at cs.byu.edu>
Assistant Professor / Brigham Young University
http://faculty.cs.byu.edu/~jay
"The glory of God is Intelligence" - D&C 93