Skip to content
/ amber-template Public template

Amber server with client apps, as Docker images to build.

License

Notifications You must be signed in to change notification settings

obiba/amber-template

Repository files navigation

Amber Template

Amber server with client apps, as Docker images to build.

Amber Applications

Amber Server API Dockerfile

Amber server is a nodejs application. Most of the runtime parameters can be set using environment variables. For advanced usage, the runtime settings can also be amended by copying a local ./config/production.json file.

Amber Studio app Dockerfile

Amber Studio is a Quasar SPA (single page application) web app delivered by a NGINX web server. The web app must be built with the site specific settings such as the Amber server URL and the reCAPTCHA site key.

Optionally, some source files can be modified as well:

  • settings.json file that is a simple way of tweaking the default theme and for adding new languages.
  • public folder that contains the app icons.
  • src/css folder that contains the SCSS files.

Amber Collect app Dockerfile

Amber Collect is a Quasar PWA (progressive web application) web app delivered by a NGINX web server. The web app must be built with the site specific settings such as the Amber server URL and the reCAPTCHA site key.

Optionally, some source files can be modified as well:

  • settings.json file that is a simple way of tweaking the default theme and for adding new languages.
  • public folder that contains the app icons.
  • src/css folder that contains the SCSS files.

Amber Visit app Dockerfile

Amber Collect is a Quasar SPA (single page application) web app delivered by a NGINX web server. The web app must be built with the site specific settings such as the Amber server URL and the reCAPTCHA site key.

Optionally, some source files can be modified as well:

  • settings.json file that is a simple way of tweaking the default theme and for adding new languages.
  • public folder that contains the app icons.
  • src/css folder that contains the SCSS files.

Home Page

This home page could be any static website of your own, that will be the landing page for redirecting the user to each of the Amber applications.

Amber Docker Compose

The production Docker files described above can be wrapped up by Docker Compose.

The following is an example of a production set up that extends the proposed template:

.
├── amber
│   ├── config
│   │   ├── email_templates
|   |   |   └── ...
│   │   └── production.json
│   └── Dockerfile
├── amber-collect
│   ├── Dockerfile
│   ├── public
│   │   ├── favicon.ico
│   │   └── icons
│   │       ├── android-icon-144x144.png
│   │       └── ...
│   ├── src
│   │   └── css
│   │       └── custom.scss
│   └── settings.json
├── amber-visit
│   ├── Dockerfile
│   ├── public
│   │   ├── favicon.ico
│   │   └── icons
│   │       ├── android-icon-144x144.png
│   │       └── ...
│   ├── src
│   │   └── css
│   │       └── custom.scss
│   └── settings.json
├── amber-studio
│   ├── Dockerfile
│   ├── public
│   │   ├── favicon.ico
│   │   └── icons
│   │       ├── android-icon-144x144.png
│   │       └── ...
│   ├── src
│   │   └── css
│   │       └── custom.scss
│   └── settings.json
├── home
│   └── index.html
├── .env
└── docker-compose.yml

The docker-compose.yml file for a production Amber runtime will then look like (environment variables are defined in the .env file, see amber's environment variables description).

Note that in this example the MongoDB server is provided by a Docker image (mongo), but it could also be externalized.

Note also the usage of the Traefik reverse proxy that allows to set up the URLs on the same base like:

To build the production Docker images, use the command:

make build

Then start the Amber server and apps with:

make up

About

Amber server with client apps, as Docker images to build.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published