[How-To] Installation of SIMON on remote server using docker

Tutorials on SIMON administration, installation or related
Post Reply
User avatar
LogIN
Admin
Posts: 16
Joined: Wed Feb 13, 2019 7:47 pm
Location: Palo Alto, CA
Contact:

Thu May 02, 2019 5:06 pm

To install SIMON on remote server you need to build your own docker image,
since you need to adjust URLs manually according to your needs.

Here you can find quick start how to do that:

First you need to clone SIMON backend repository and continue from there.
https://github.com/genular/simon-backend

Code: Select all

cd /mnt/data/grenular/simon-backend
git clone https://github.com/LogIN-/simon-backend .

# 2. Now you need to adjust variables and build child genular SIMON image
cd documentation/docker_images

# You need to adjust your URLs in following two configuration files
# configuration.example.json if used by simon-backend
# Dockerfile is used on simon-frontend on javascript side

# 3. After you adjusted your configuration, you are ready to build an image
docker build --no-cache --network=host --tag "genular/simon:my_image" --file ./Dockerfile .

# 4. Thats it! Now you can run that image you just created in regular way.
More information about docker building process is located here:
https://github.com/genular/simon-backend/tree/master/documentation/docker_images

Please don't forgot if needed to configure nginx as a reverse proxy to translate requests to your hostname to docker published ports.

Example of nginx reverse proxy's:

Code: Select all

server {
    listen [::]:80;
    server_name backend.example.localhost;

    client_max_body_size 1024M;
    charset utf-8;

    location / {
        proxy_http_version  1.1;
        proxy_set_header    Host            $host;
        proxy_set_header    X-Real-IP       $remote_addr;
        proxy_set_header    X-Forwarded-for $remote_addr;
        ## Pass traffic to PM2 R server
        proxy_pass http://127.0.0.1:3011;
    }
}

Code: Select all

server {
    listen [::]:80;
    server_name plots.example.localhost;

    client_max_body_size 1024M;
    charset utf-8;

    location / {
        proxy_http_version  1.1;
        proxy_set_header    Host            $host;
        proxy_set_header    X-Real-IP       $remote_addr;
        proxy_set_header    X-Forwarded-for $remote_addr;
        ## Pass traffic to PM2 R server
        proxy_pass http://127.0.0.1:3013;
    }
}

Code: Select all

server {
	listen [::]:80;
    server_name analysis.example.localhost;

    client_max_body_size 1024M;
    charset utf-8;

    location / {
        proxy_http_version  1.1;
        proxy_set_header    Host            $host;
        proxy_set_header    X-Real-IP       $remote_addr;
        proxy_set_header    X-Forwarded-for $remote_addr;
        proxy_pass http://127.0.0.1:3012;
    }
}
“We can not solve our problems with the same level of thinking that created them” A.E.
Post Reply