Commit Graph

12 Commits

Author SHA1 Message Date
Marsell Kukuljevic 068c31a93d TRIX-19 - remove excess logging back-end. 2021-05-29 22:27:54 +02:00
Marsell Kukuljevic d07d11cf04 Update backend to reflect that SPA now loads package and image rates from
static/assets/data/(images|packages).json
2021-04-29 13:32:12 +02:00
Marsell Kukuljevic 17e2a5f86a Add support for serving gzipped static content. Between minification and
this, the client-size app is now about 1MB in size when built for production.
2021-04-28 17:28:31 +02:00
Marsell Kukuljevic 1ed6c05011 Add support for /rates/packages.json and /rates/images.json. These files are
served up from the rates/ directory, although in production the current in-repo
files are substituted with JSON pulled in from the VM's internal_metadata
configuration.
2021-04-27 00:03:21 +02:00
Marsell Kukuljevic 54b911bcd4 When server.js receives a static path it does not recognize, it serves up
index.html instead. This is useful when a user reloads a page in the SPA --
server.js does not know this path, but by serving up the SPA again the SPA
knows how to handle that URL. This makes the app behave in a manner a user
expects when reloading a page.
2021-04-26 22:32:35 +02:00
Marsell Kukuljevic db8758cc30 Attempt to fix 408 errors from the cueball connection pool. The pool now
regularly pings cloudapi's /. Also (temporarily) silenced cueball noise.
2021-04-11 00:07:01 +02:00
Marsell Kukuljevic 3c38a932ed Log all requests, using the bunyan format (JSON with certain fields). This
is most easily consumed with the bunyan formatter; see README.md for more
details.
2021-04-10 23:06:24 +02:00
Marsell Kukuljevic 8672439358 Changed how paths are handled by server.js, to more closely match the Angular
dev environment. New paths:

/api/login: redirects to SSO
/api: all calls (other than above) are sent to cloudapi
/: static content served from static/

All API calls to cloudapi now pass through server.js's HTTP /api, not /.

The static/static path is now gone, since it was causing too much trouble.
static/ is now a symlink directly to app/dist, which is where a fresh Angular
build appears when app/ is built.
2021-04-10 21:50:50 +02:00
Marsell Kukuljevic 18d35b5172 Eliminate /token path from server.js, to match Dragos' env. 2021-04-10 20:41:30 +02:00
Marsell Kukuljevic 991f5cabdc Fix the handling of DELETE and PUT calls, and stop unintentional deserialization
of JSON instead of passing it through as an opaque string.
2021-03-26 22:46:57 +01:00
Marsell Kukuljevic 6aea7758ee Server uses TLS, sign all requests to cloudapi, and enable SSO. 2021-01-26 17:22:37 +01:00
Marsell Kukuljevic 9abb845eec Basic proxying to cloudapi, and serving static content. 2021-01-12 23:39:15 +01:00