Created
October 20, 2015 11:13
-
-
Save parambirs/1f6d3e43dd7700a21262 to your computer and use it in GitHub Desktop.
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
| FROM haskell:7.10 | |
| RUN cabal update | |
| # Add .cabal file | |
| ADD ./scotty-webapp-example.cabal /opt/server/scotty-webapp-example.cabal | |
| # Docker will cache this command as a layer, freeing us up to | |
| # modify source code without re-installing dependencies | |
| RUN cd /opt/server && cabal install --only-dependencies -j4 | |
| # Add and Install Application Code | |
| ADD ./server /opt/server/server | |
| ADD ./LICENSE /opt/server/LICENSE | |
| RUN cd /opt/server && cabal install | |
| # Add installed cabal executables to PATH | |
| ENV PATH /root/.cabal/bin:$PATH | |
| # Default Command for Container | |
| WORKDIR /opt/server | |
| CMD ["scotty-webapp-example"] |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment