|
|
|
|
|
by microtonal
4844 days ago
|
|
Yesod is great, especially its quasi quoters, such as Hamlet. However, two things that I constantly bumped into maintaining a small Yesod app is that there was a fairly constant stream of API changes and that deployment on different machines was annoying because of version conflicts installing packages. If you use Yesod, you are probably best off using a Cabal sandbox (e.g. via cabal-dev) and making specific package versions dependencies. Of course, that may be questionable from a security perspective. I ended up rewriting that particular web app to Play, which offers some of the same benefits, but was a lot easier to deploy. You can create a stand-alone version of an application with play dist, which includes all the required jars, and the only thing required on a server is the Java runtime environment. Also, Maven/sbt seems a lot more mature than Cabal. As an added advantage, you can use tried and tested Java or can go all-functional via Scala. |
|
I know fpcomplete use stackage for their School of Haskell[2]. This way, there is never any package dependency problem. Which gives them the incredible ability to execute yesod application directly on their server from the code of an user changing the code in the browser. If you haven't did it yet, you should really try it.
Also, concerning the deployment, having a single statically linked binary is very similar to having a single jar file. And this is very easy to deploy using heroku for example.
You can ask me more detail if you want to know how I deploy my application but this is mostly very well documented in the wiki.
[1]: https://github.com/fpco/stackage [2]: https://www.fpcomplete.com/school