Skip to content

Commit f790fed

Browse files
committed
Implements /healthz. Updates Node
1 parent 59d7873 commit f790fed

File tree

4 files changed

+16
-4
lines changed

4 files changed

+16
-4
lines changed

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# Setting the base to docker-node-unoconv
2-
FROM telemark/docker-node-unoconv:8.7.0
2+
FROM telemark/docker-node-unoconv:8.8.1
33

44
# Maintainer
55
MAINTAINER Geir Gåsodden

README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,18 @@ To see formats for a given type ```/unoconv/formats/{document|graphics|presentat
4141

4242
To see all versions of installed dependencies lookup ```/unoconv/versions```
4343

44+
### Healthz
45+
46+
Are we alive? ```/healthz```
47+
48+
returns
49+
50+
```JavaScript
51+
{
52+
uptime: 18.849
53+
}
54+
```
55+
4456
## Environment
4557

4658
You can change the webservice port and filesize-limit by changing environment variables.

handlers/index.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,5 +81,5 @@ module.exports.showVersions = (request, reply) => {
8181
}
8282

8383
module.exports.healthcheck = (request, reply) => {
84-
reply('ok')
84+
reply({uptime: process.uptime()})
8585
}

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "tfk-api-unoconv",
3-
"version": "3.1.1",
3+
"version": "3.2.0",
44
"private": true,
55
"description": "Unoconv as a webservice",
66
"author": {
@@ -15,7 +15,7 @@
1515
"homepage": "https://github.com/zrrrzzt/tfk-api-unoconv",
1616
"main": "index.js",
1717
"engines": {
18-
"node": ">=8.7.0"
18+
"node": ">=8.8.1"
1919
},
2020
"scripts": {
2121
"test": "standard && nsp check && tap --reporter=spec test/**/*.js",

0 commit comments

Comments
 (0)