This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Upstart script for a play application that binds to an unprivileged user. | |
| # put this into a file like /etc/init/play.conf | |
| # | |
| # This could be the foundation for pushing play apps to the server using something like git-deploy | |
| # By calling service play stop in the restart command and play-start in the restart command. | |
| # | |
| # Usage: | |
| # start play | |
| # stop play | |
| # restart play |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (ns fileupload.core | |
| (:use [net.cgrand.enlive-html | |
| :only [deftemplate defsnippet content clone-for | |
| nth-of-type first-child do-> set-attr sniptest at emit*]] | |
| [compojure.core] | |
| [ring.adapter.jetty]) | |
| (:require (compojure [route :as route]) | |
| (ring.util [response :as response]) | |
| (ring.middleware [multipart-params :as mp]) | |
| (clojure.contrib [duck-streams :as ds])) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| (import 'org.apache.commons.mail.SimpleEmail) | |
| (doto (SimpleEmail.) | |
| (.setHostName "smtp.gmail.com") | |
| (.setSslSmtpPort "465") | |
| (.setSSL true) | |
| (.addTo "you@gmail.com") | |
| (.setFrom "you@gmail.com" "Lucky Clojurian") | |
| (.setSubject "Hello from clojure") | |
| (.setMsg "Wasn't that easy?") | |
| (.setAuthentication "you@gmail.com" "yourpassword") |
NewerOlder