Public | Automated Build

Last pushed: 2 days ago
Short Description
Bootstrap app for EEA Nodejs Elasticsearch apps
Full Description

Bootstrap app for Nodejs Elasticsearch apps

This application is just a simple demo what can be used as a basis for new applications.

It provides the basic indexing commands indexing, listing and detail pages,
csv/tsv export.

It can be cloned, and with minimal configuration a new search application
created from it.



Basic usage of the image is given by the following pattern:

docker run -d -v /path/of/your/config/:/code/config:z -p 8080:3000 -e "elastic_host=<elasticsearch_host_or_ip>" eeacms/esbootstrap:v1.0
  • <elasticsearch_host_or_ip> is the url or the ip of your elastic search server without the port
  • ./config is the folder that contains the configuration files for your app. Read this to know how to configure.

Using rancher

Read this to know how to setup.

Using eea.docker.searchservices

For creating a new application you have to follow the next steps:

1. Clone eea.docker.searchservices on the development machine

$ git clone --recursive

2. Clone the eea.docker.esbootstrap

$ cd eea.docker.searchservices
$ # clone eea.docker.esbootstrap under eea.docker.searchservices and gives new name: eea.docker.newesapp
$ git clone eea.docker.newesapp

3. Configure the new app

The config folder contains the configuration files for your app. Read this to know how to configure the files for your app.

4. Configure the eea.docker.searchservices to include the new application

4.1. Add it in the file

Clone the file under the name and add to it the settings for development

image: eeacms/esbootstrap:dev # Work with dev build
- esclient
- 3030:3000 # Take up an empty port number
- elastic_host=esclient
- AUTO_INDEXING=true #index data when the app is started for the first time
# - SYNC_CRONTAB=/30 * # This is optional, it executes the sync with a cronjob every 30 minutes
# - GOOGLE_MAP_KEY=google-map-api-key # To enable google map extention functionality in geo facet assign a valid key generated at
- ./eea.docker.newesapp/app/:/code/:z # the volumes are added for easier development
- ./eea.searchserver.js/lib/:/node_modules/eea-searchserver/lib/:z

4.2. Testing the application

In eea.docker.searchservices:
At first try you have to build all development images for the applications

./ -s
Later, when you modify your application, is enough to rebuild only that. This is not mandatory, as in the we already mounted the code in the container, but when you want to try to build the image, is enough to do:
./ newesapp -s

4.3. Start the whole stack

In eea.docker.searchservices start the whole stack with:

docker-compose -f up

4.4. Test in the browser

In your favorite browser go to:

http://<machine ip>:<port>

5. Add it to the production stack

After there is a first working version of the application, you should

  • add it in the stack as a git submodule for eea.docker.searchservices
  • create a git tag for eea.docker.newesapp
  • add the application in and enable automatic build on tags
  • add your application in docker-compose.yml from eea.docker.searchservices and pin it to the tag you added


For details on implementation read the documentation.

Docker Pull Command
Source Repository