Skip to content

Commit

Permalink
add healthz in Docker, update URLs
Browse files Browse the repository at this point in the history
  • Loading branch information
hpratt committed Sep 16, 2019
1 parent 992214f commit 48a4b4c
Show file tree
Hide file tree
Showing 6 changed files with 11 additions and 6 deletions.
1 change: 1 addition & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,4 +14,5 @@ RUN yarn build
RUN yarn global add serve

# start app
EXPOSE 80
CMD ["node", "server.js"]
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "logosj-webapp",
"version": "1.0.4",
"version": "1.0.5",
"license": "MIT",
"author": "Henry Pratt",
"homepage": "/app",
Expand Down
4 changes: 4 additions & 0 deletions server.js
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ const lookupComponent = glyph => {
return nglyph;
};

app.get('/healthz', (req, res) => {
res.status(200).send("healthy\n");
});

app.get('/svg/:s', (req, res) => {

const logo = decodeSvg(req.params.s);
Expand Down
2 changes: 1 addition & 1 deletion src/common/codestrings.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ export const jsCodestring = js => `
<!doctype html>
<html>
<body>
<script src="https://package.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<script src="http://bundle.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<div id="logo" style="width:500px"></div>
<script type="text/javascript">
${indentCode(js, " ")}
Expand Down
6 changes: 3 additions & 3 deletions src/components/gallery/annotated/config.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export const ANNOTATED_CODESTRING_JS = `
<!doctype html>
<html>
<body>
<script src="https://package.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<script src="http://bundle.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<div style="width:500px">
<svg viewBox="0 0 1530 330">
<g transform="translate(20,-40)" id="logo"></g>
Expand Down Expand Up @@ -104,7 +104,7 @@ export const SNP_CODESTRING_JS = `
<!doctype html>
<html>
<body>
<script src="https://package.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<script src="http://bundle.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<div style="width:500px">
<svg viewBox="0 0 1100 420">
<rect x="600" width="100" height="420" fill="#bbbbbb"></rect>
Expand Down Expand Up @@ -192,7 +192,7 @@ export const INTERACTION_CODESTRING_JS = `
<!doctype html>
<html>
<body>
<script src="https://package.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<script src="http://bundle.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<div style="width:500px">
<svg viewBox="0 0 2600 920">
<g id="dnalogo"></g>
Expand Down
2 changes: 1 addition & 1 deletion src/components/gallery/dna/config.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -190,7 +190,7 @@ export const NOAXIS_CODESTRING_JS = `
<!doctype html>
<html>
<body>
<script src="https://package.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<script src="http://bundle.logosj.wenglab.org/bundle.js" type="text/javascript"></script>
<div style="width:500px">
<svg viewBox="0 0 1900 100">
<g id="logo"></g>
Expand Down

0 comments on commit 48a4b4c

Please sign in to comment.