fix typo, add health check

master
radex 2024-01-31 09:24:57 +01:00
parent 4690cd2cf8
commit 97000ad207
Signed by: radex
SSH Key Fingerprint: SHA256:hvqRXAGG1h89yqnS+cyFTLKQbzjWD4uXIqw7Y+0ws30
1 changed files with 5 additions and 1 deletions

View File

@ -69,12 +69,16 @@ end
set :bind, '0.0.0.0'
get '/api/2/health' do
"I'm cool"
end
get '/api/2/preview.pdf' do
headers["Content-Type"] = "application/pdf; charset=utf8"
render_label
end
post '/api/1/print' do
post '/api/2/print' do
temp = Tempfile.new('labelmaker')
temp.write(render_label)
temp.close