+
diff --git a/app/views/navbar.scala.html b/app/views/navbar.scala.html
new file mode 100644
index 0000000..ab86d61
--- /dev/null
+++ b/app/views/navbar.scala.html
@@ -0,0 +1,7 @@
+
diff --git a/app/views/users/login.scala.html b/app/views/users/login.scala.html
new file mode 100644
index 0000000..85916c0
--- /dev/null
+++ b/app/views/users/login.scala.html
@@ -0,0 +1,11 @@
+
diff --git a/build.sbt b/build.sbt
index 74c87a0..4c0432b 100644
--- a/build.sbt
+++ b/build.sbt
@@ -7,15 +7,17 @@ lazy val root = (project in file(".")).enablePlugins(PlayScala)
scalaVersion := "2.11.6"
libraryDependencies ++= Seq(
- jdbc,
cache,
ws,
specs2 % Test,
"com.typesafe.play" %% "play-slick" % "1.0.0",
- "org.postgresql" % "postgresql" % "9.4-1200-jdbc4"
+ "com.typesafe.play" %% "play-slick-evolutions" % "1.0.0",
+ "org.postgresql" % "postgresql" % "9.4-1200-jdbc4",
+ "org.mindrot" % "jbcrypt" % "0.3m"
)
resolvers += "scalaz-bintray" at "http://dl.bintray.com/scalaz/releases"
+resolvers += "jbcrypt repo" at "http://mvnrepository.com/"
// Play provides two styles of routers, one expects its actions to be injected, the
// other, legacy style, accesses its actions statically.
diff --git a/conf/application.conf b/conf/application.conf
index 2b5b281..a6f20ae 100644
--- a/conf/application.conf
+++ b/conf/application.conf
@@ -1,51 +1,16 @@
-# This is the main configuration file for the application.
-# ~~~~~
-
-# Secret key
-# ~~~~~
-# The secret key is used to secure cryptographics functions.
-#
-# This must be changed for production, but we recommend not changing it in this file.
-#
-# See http://www.playframework.com/documentation/latest/ApplicationSecret for more details.
play.crypto.secret = "changeme"
-# The application languages
-# ~~~~~
play.i18n.langs = [ "en" ]
-# Router
-# ~~~~~
-# Define the Router object to use for this application.
-# This router will be looked up first when the application is starting up,
-# so make sure this is the entry point.
-# Furthermore, it's assumed your route file is named properly.
-# So for an application router like `my.application.Router`,
-# you may need to define a router file `conf/my.application.routes`.
-# Default to Routes in the root package (and conf/routes)
-# play.http.router = my.application.Routes
-
-# Database configuration
-# ~~~~~
-# You can declare as many datasources as you want.
-# By convention, the default datasource is named `default`
-#
-# db.default.driver=org.h2.Driver
-# db.default.url="jdbc:h2:mem:play"
-# db.default.user=sa
-# db.default.password=""
-
-testdb: {
- driver: "org.postgresql.Driver",
- url: "jdbc:postgresql://localhost:5432/play_app",
- user: "fh",
- password: ""
+slick.dbs {
+ testdb: {
+ driver: "slick.driver.PostgresDriver$"
+
+ db: {
+ driver: "org.postgresql.Driver",
+ url: "jdbc:postgresql://localhost:5432/play_app",
+ username: "fh",
+ password: ""
+ }
+ }
}
-
-# Evolutions
-# ~~~~~
-# You can disable evolutions if needed
-# play.evolutions.enabled=false
-
-# You can disable evolutions for a specific datasource if necessary
-# play.evolutions.db.default.enabled=false
diff --git a/conf/evolutions/testdb/1.sql b/conf/evolutions/testdb/1.sql
new file mode 100644
index 0000000..657b54e
--- /dev/null
+++ b/conf/evolutions/testdb/1.sql
@@ -0,0 +1,14 @@
+# Users schema
+
+# --- !Ups
+
+CREATE TABLE "users" (
+ id bigserial primary key,
+ email varchar(255) not null,
+ password varchar(255) not null,
+ salt varchar(255) not null
+);
+
+# --- !Downs
+
+DROP TABLE "users";
diff --git a/conf/routes b/conf/routes
index e71a0bd..a48def1 100644
--- a/conf/routes
+++ b/conf/routes
@@ -1,9 +1,9 @@
-# Routes
-# This file defines all application routes (Higher priority routes first)
-# ~~~~
-
-# Home page
GET / controllers.Application.index
+# User routes
+GET /users/login controllers.Users.login
+
+POST /sessions/create controllers.Sessions.create
+
# Map static resources from the /public folder to the /assets URL path
GET /assets/*file controllers.Assets.versioned(path="/public", file: Asset)