#PAMM Skeleton
##Contents
The PAMM Skeleton project is a quick start, template project using the PAMM stack. It is designed to be barebones so that developers can download and start coding business requirements rapidly with no set-up required. The project is based off the "hello-play-2.3-scala" template provided within Activator, however significant changes have been made.
##Technology Stack
- Scala
- Play 2.4.3
- SBT 0.13.8
- Angular 1.5.5
- Bootstrap 3.3.6
- MongoDB (sample integration provided via Casbah)
##Installation Instructions
Note: Running the 'sbt' commands from behind the Atos Proxy may result in compilation errors, if sbt needs to download missing dependencies
###Basic
git clone
- Browse to the directory root
sbt compile
to ensure the solution buildssbt run
to start the application- Browse to
http://localhost:9000
from your browser to see the application
###IntelliJ
- Complete the steps above to download the solution
- Import the project into IntelliJ
- Open IntelliJ
- Select 'Open'
- Select the root folder of the project
- Select to import as an SBT project
- Select 'auto import'
- Configure IntelliJ to run the project
- Go to "Run" on the menu
- Select 'Edit Configurations'
- Add a new configuration by processing the + button in the top left
- Select 'SBT Task'
- Set the 'Name' to be "SBT Run"
- Set the 'task' to be "clean compile run"
- Remove 'Make' from the 'Before Launch' tasks
- Click Apply and close the menu
- You can now run/debug the application using the "SBT Run" option from the IntelliJ Run menu
###MongoDB This project includes Casbah, a Scala toolkit for MongoDB. It's usage is optional, and it can be replaced with a suitable alternative if required. A controller has been provided with an example of simple database interactions, and should be adapted or removed as needed.
####Configuration There are 3 options for configuring which MongoDB instance the application uses:
- Set the
$MONGODB_URI
environment variable to the appropriate URI, this will be taken over the defaults set withinapplication.conf
. - Change the target MongoDB URI within the
application.conf
file. Altering the first instance ofmongodb.uri
will change the default instance of MongoDB used by the application providing the environment variable is not present. - Leave it as the default, which assumes the database is running on localhost under the default port (27017).
More detail on MongoDB URIs can be found at: https://docs.mongodb.com/manual/reference/connection-string/