How IGWEB operates in production mode

Before proceeding to production deployment, we need to understand how the server-side web application, igweb, operates when it's placed into production mode. Production mode can be turned on by setting the IGWEB_MODE environment variable with the value "production" before starting the igweb server-side application, like so:

$ export IGWEB_MODE=production

There are three important behaviors that will take place when IGWEB runs in production mode:

  1. The JavaScript external <script> tag that includes the client-side application, inside the header partial template, will request the minified JavaScript source file located at $IGWEB_APP_ROOT/static/js/client.min.js.
  2. Static assets for cogs (cogimport.css and cogimport.js) will not be generated automatically when the web server instance starts. Instead, the minified source files containing the bundled static assets for the CSS and JavaScript will be located at $IGWEB_APP_ROOT/static/css/cogimports.min.css and $IGWEB_APP_ROOT/static/js/cogimports.min.js, respectively.
  3. Rather than relying on the templates found in the $IGWEB_APP_ROOT/shared/templates folder, templates will be read from a single, gob encoded, template bundle file persisted on the disk.

We are going to consider how the server-side web application responds to each one of these behaviors.

..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.221.197.95