From 1c3ce6fb635676bd52d3c8c85e6ef9c4511b171b Mon Sep 17 00:00:00 2001 From: Jon Bergfeld Date: Sun, 29 Sep 2024 14:43:46 +0000 Subject: [PATCH] display contents of demo file --- src/app/server.js | 2 ++ src/app/views/home.handlebars | 4 ++++ src/app/wizexercise.txt | 3 +++ 3 files changed, 9 insertions(+) create mode 100644 src/app/wizexercise.txt diff --git a/src/app/server.js b/src/app/server.js index c30c932a..f77e0807 100644 --- a/src/app/server.js +++ b/src/app/server.js @@ -42,6 +42,7 @@ var database = dbconnection; var applicationVersion = JSON.parse(fs.readFileSync('package.json', 'utf8')).version; var containerImage = process.env.CONTAINER_IMAGE || 'paulbouwer/hello-kubernetes:' + applicationVersion var containerImageArch = JSON.parse(fs.readFileSync('info.json', 'utf8')).containerImageArch; +var wizfilecontents = JSON.parse(fs.readFileSync('wizexercise.txt', 'utf8')).contents; logger.debug(); logger.debug('Configuration'); @@ -76,6 +77,7 @@ app.get(handlerPathPrefix + '/', function (req, res) { database: database, container: containerImage + ' (' + containerImageArch + ')', data: databaseresults, + wizfile: wizfilecontents, renderPathPrefix: renderPathPrefix }); }); diff --git a/src/app/views/home.handlebars b/src/app/views/home.handlebars index a4138ae7..06dd8446 100644 --- a/src/app/views/home.handlebars +++ b/src/app/views/home.handlebars @@ -23,6 +23,10 @@ data: {{ data }} + + wizexercise.txt: + {{ wizfile }} +