Skedler Reports is now available in the Docker Compose. It is a tool for defining and running multi-container (Skedler Reports ) Docker applications. With Compose, you use a YAML file to configure your application's services. Then with a single command, you create and start all the services from your configuration. 

  • Install Docker Compose (Note: docker-compose is not pre-installed with Docker on Linux)   

  • Install docker-compose following the installation instructions that can be found here  

Step-by-Step Instruction

Step 1: Define service in a Compose file:

Create a file called docker-compose.yml in your project directory and paste the following 

  • docker-compose.yml:  

    version: '2.2'
        image: skedler/reports:latest
        container_name: reports
        privileged: true
          - SYS_ADMIN
          - /sys/fs/cgroup:/sys/fs/cgroup:ro
          - reportdata:/var/lib/skedler
          - ./reporting.yml:/opt/skedler/config/reporting.yml
        command: opt/skedler/bin/skedler
          - 3000:3000
          - skedlernet
        driver: local

This Compose file defines the service of Skedler Reports . 

Step 2: Basic Skedler configurations using reporting.yml  

Create a files called reporting.yml in your project directory. 

  • Getting the reporting.yml file found here   

a) Configure Skedler Reports Configuration like port, kibana_index, Elasticsearch URL, Kibana URL, Grafana URl and skedler_index in reporting.yml

  • port - The port in which skedler runs. Default port is 3000
  • elasticsearch_url - Elasticsearch URL with the port (even if the port is 80) in the following format <protocol>://<server>:<port> 
  • kibana_url - Kibana URL with the port in the following format <protocol>://<server>:<port
  • grafana_url - Grafana URL with the port in the following format <protocol>://<server>:<port>

Note: For more configuration options kindly refer the article reporting.yml and ReportEngineOptions Configuration 

Note: The following folders are persisted in the mapped volume (ie reportdata)

  • Log files -  log_dir: Persist log information in /var/lib/skedler/logs folder.
  • Custom images, images and custom CSS - ui_files_location: Persist UI information in /var/lib/skedler/uifiles folder.
  • Database - Persist Skedler infomations in /var/lib/skedler/skedler.db and /var/lib/skedler/skedlerHistory.db
  • *Reports -  reports_dir: Persist generated report information in /var/lib/skedler/reports folder.

Note: *Report generation path needs to be configured for "Base Folder Directory" as "/var/lib/skedler/reports" in the Skedler configuration page to persist the generated reports.

Step 3: Build and run your app with compose

From your project directory, start up your application by running 

sudo docker-compose up

Compose pulls a Skedler Reports image, builds an image for your code, and starts the services you defined

Enter http://<hostIP>:3000 in a browser to see the Skedler Reports application running 

If you want to run your services in the background, you can pass the -d flag (for "detached" mode) to docker-compose up and docker-compose ps to see what is currently running

sudo docker-compose up -d

To stop the service use the following command:

sudo docker-compose down

You can bring everything down, removing the containers entirely, with the down command. Pass --volumes to also remove the data volume just type:

sudo docker-compose down -v

How to generate debug logs for Skedler Reports in Docker Compose

Note: If you are face an issue in running Skedler Reports in Docker Compose, the support team will request you to run skedler in debug mode and upload the log files .  

For Skedler Reports change the "command" keyword in the docker-compose.yml as shown below,  

command: opt/skedler/bin/skedler debug