Various fixes

- Fix nginx paths for db component
- Install ghostscript packages used for PDF manipulation

Change-Id: I3bc6bb33ca33cc38c527933d171d4858d5ec2482
diff --git a/molecule/default/prepare.yml b/molecule/default/prepare.yml
index ce920eb..7a83c08 100644
--- a/molecule/default/prepare.yml
+++ b/molecule/default/prepare.yml
@@ -21,8 +21,8 @@
         default_server: true
         custom_root: "/opt/timesheets/ui/dist/timesheetsui"
         extra_config: |
-          location /rest {
-            proxy_pass            http://localhost:3000;
+          location /rest/ {
+            proxy_pass            http://localhost:3000/;
             proxy_buffering       off;
             proxy_http_version    1.1;
             proxy_read_timeout    60;
diff --git a/molecule/default/verify.yml b/molecule/default/verify.yml
index fcced9b..24859be 100644
--- a/molecule/default/verify.yml
+++ b/molecule/default/verify.yml
@@ -17,3 +17,13 @@
         return_content: true
       register: timesheet_root_page
       failed_when: "'Timesheetsui' not in timesheet_root_page.content"
+
+    - name: Obtain the /rest/ webpage, check that it's from timesheetsdb
+      uri:
+        url: http://127.0.0.1/
+        headers:
+          Host: "timesheets.example.com"
+        status_code: 200
+        return_content: true
+      register: timesheet_rest_page
+      failed_when: "'Hello World' not in timesheet_rest_page.content"
diff --git a/tasks/Debian.yml b/tasks/Debian.yml
index 95366c6..4d214df 100644
--- a/tasks/Debian.yml
+++ b/tasks/Debian.yml
@@ -9,6 +9,8 @@
   apt:
     name:
       - "git"
+      - "ghostscript"
+      - "graphicsmagick"
     state: "present"
     update_cache: true
     cache_valid_time: 3600