Tandoor Recipes Organizer Interface (TROI) on a Synology Disk Station

Currently reading
Tandoor Recipes Organizer Interface (TROI) on a Synology Disk Station

280
79
NAS
DS920+, DS916+, DS211j
Operating system
  1. macOS
  2. Windows
Mobile operating system
  1. Android
  2. iOS
Hi,
Came across this great docker container and would like to share it with you guys (if anyone is interested).
It is well documented in a pdf. More info can be found here: tandoor.
 

Attachments

  • Tandoor.on.a.Synology.Disk.Station.pdf
    1.5 MB · Views: 360
Hi,

I appreciate this very helpful description. Thanks @BobW for sharing.

Did anyone here install "Tandoor Recipes" as Container on his/her Syno? I did so yesterday with "latest" 1.0.4-version - everything works as it should but I cannot load and view pictures. The log from nginx-proxy shows an error that */recipes/media/*.jepg cannot be found. The folders /mediafiles and /staticfiles, which seem correctly mapped to the paths inside the web application and proxy-containers show no content so far. text is stored in the database as it should. only pictures cannot be loaded.
I already checked all the configurations and also tried some workarounds e.g. w/o reverse proxy - but always w/ the same effect.

Anyone here who could give me hint?

Rgds, Tori
 
Hi @tori

I tried it when I came across it. I have since removed it from my Synology.

To be honest, I can't remember if it worked to put pictures in the recipes myself.
What I do remember is that importing recipes worked, I imported some recipes from recipe sites and the pictures were just visible there and in de media folder.

Have you tried that yet? If not maybe you should try that first and see if the pictures are visible and saved in the media folder.

And check the user permission of the folders again, if they are correct.
That’s all I can think off at the moment, sorry😌
 
Hi,

just did an import from url. In my preview I could see the picture. After the import it was gone - unfortunately. And - as expected then - no items in /mediafiles or /staticfiles.

The hint about the access rights may lead to a solution. Checking the rights in File Station shows for the db-folder an empty owner and empty rights section - strange but w/i this folder read/write seems to work. /mediafiles/ as well as /staticfiles/ and /nginx/ inherited owner "admin" and show a greyed rigths-section with read/write for e.g. "http", "admin" and user specific rights for "owner".

How should the rights be set the right way? Any idea?

Rgds, Tori
 
Hi,
I have reinstalled the containers, but this time I used docker-compose. And everything is working fine on my end.
I can add pictures and they shows on the recipe and also saved in the mediafiles folder. I also tried to import from an URL and from there the pictures has saved into the mediafiles folder.

About the folder permissions.
I see the following permissions with my folders: (Group:Owner)
db folder = Users:70
mediafiles = Root:Root
staticfiles = Root:Root

You can change the permissions using terminal.

If you want to try the docker-compose versions here is my docker-compose file, alter it to your needs:


YAML:
version: '3.8'

services:
  recipes-db:
    container_name: recipes-db
    image: postgres:11-alpine
    restart: "no"
    hostname: recipes-db
    env_file: .env
    security_opt:
      - no-new-privileges:true
    mem_limit: 85m
    mem_reservation: 85m
    ports:
      - 5434:5432/tcp
    volumes:
      - /volume1/docker/recipes/db:/var/lib/postgresql/data:rw
      - /etc/localtime:/etc/localtime:ro
      - /etc/TZ:/etc/timezone:ro
    environment:
      - TZ=your/timezone
    networks:
      - recipes_network

  recipes-web:
    container_name: recipes-web
    image: vabene1111/recipes:latest
    restart: "no"
    hostname: recipes-web
    env_file: .env
    security_opt:
      - no-new-privileges:true
    mem_limit: 85m
    mem_reservation: 85m
    depends_on:
      - recipes-db
    volumes:
      - /volume1/docker/recipes/nginx/conf.d:/opt/recipes/nginx/conf.d
      - /volume1/docker/recipes/staticfiles:/opt/recipes/staticfiles
      - /volume1/docker/recipes/mediafiles:/opt/recipes/mediafiles
      - /etc/localtime:/etc/localtime:ro
      - /etc/TZ:/etc/timezone:ro
    environment:
      - TZ=your/timezone
    networks:
      - recipes_network

  recipes-nginx:
    container_name: recipes-nginx
    image: nginx:mainline-alpine
    restart: "no"
    hostname: recipes-nginx
    env_file: .env
    security_opt:
      - no-new-privileges:true
    mem_limit: 85m
    mem_reservation: 85m
    depends_on:
      - recipes-web
    ports:
      - 3080:80
    volumes:
      - /volume1:/etc/nginx/conf.d:ro
      - /volume1/docker/recipes/staticfiles:/static
      - /volume1/docker/recipes/mediafiles:/media
      - /etc/localtime:/etc/localtime:ro
      - /etc/TZ:/etc/timezone:ro
    environment:
      - TZ=your/timezone
    networks:
      - recipes_network

networks:
  recipes_network:
    name: recipes_network

Place the following file Recipes.conf in the /docker/recipes/nginx/conf.d folder
Code:
server {
  listen 80;
  server_name localhost;

  client_max_body_size 128M;

  # serve media files
  location /media/ {
    alias /media/;
  }
  # pass requests for dynamic content to gunicorn
  location / {
    proxy_set_header Host $http_host;
    proxy_pass http://recipes-web:8080;
  }
}

Copy the env.template file to your docker folder and save it as .env and alter to you needs
env.template

Run the docker-compose after you finished changing everything to your needs
Code:
cd /volume1/docker/recipes
docker-compose -p "recipes" up -d
 
Hi,
I have reinstalled the containers, but this time I used docker-compose. And everything is working fine on my end.
I can add pictures and they shows on the recipe and also saved in the mediafiles folder. I also tried to import from an URL and from there the pictures has saved into the mediafiles folder.

About the folder permissions.
I see the following permissions with my folders: (Group:Owner)
db folder = Users:70
mediafiles = Root:Root
staticfiles = Root:Root

You can change the permissions using terminal.

If you want to try the docker-compose versions here is my docker-compose file, alter it to your needs:


YAML:
version: '3.8'

services:
  recipes-db:
    container_name: recipes-db
    image: postgres:11-alpine
    restart: "no"
    hostname: recipes-db
    env_file: .env
    security_opt:
      - no-new-privileges:true
    mem_limit: 85m
    mem_reservation: 85m
    ports:
      - 5434:5432/tcp
    volumes:
      - /volume1/docker/recipes/db:/var/lib/postgresql/data:rw
      - /etc/localtime:/etc/localtime:ro
      - /etc/TZ:/etc/timezone:ro
    environment:
      - TZ=your/timezone
    networks:
      - recipes_network

  recipes-web:
    container_name: recipes-web
    image: vabene1111/recipes:latest
    restart: "no"
    hostname: recipes-web
    env_file: .env
    security_opt:
      - no-new-privileges:true
    mem_limit: 85m
    mem_reservation: 85m
    depends_on:
      - recipes-db
    volumes:
      - /volume1/docker/recipes/nginx/conf.d:/opt/recipes/nginx/conf.d
      - /volume1/docker/recipes/staticfiles:/opt/recipes/staticfiles
      - /volume1/docker/recipes/mediafiles:/opt/recipes/mediafiles
      - /etc/localtime:/etc/localtime:ro
      - /etc/TZ:/etc/timezone:ro
    environment:
      - TZ=your/timezone
    networks:
      - recipes_network

  recipes-nginx:
    container_name: recipes-nginx
    image: nginx:mainline-alpine
    restart: "no"
    hostname: recipes-nginx
    env_file: .env
    security_opt:
      - no-new-privileges:true
    mem_limit: 85m
    mem_reservation: 85m
    depends_on:
      - recipes-web
    ports:
      - 3080:80
    volumes:
      - /volume1:/etc/nginx/conf.d:ro
      - /volume1/docker/recipes/staticfiles:/static
      - /volume1/docker/recipes/mediafiles:/media
      - /etc/localtime:/etc/localtime:ro
      - /etc/TZ:/etc/timezone:ro
    environment:
      - TZ=your/timezone
    networks:
      - recipes_network

networks:
  recipes_network:
    name: recipes_network

Place the following file Recipes.conf in the /docker/recipes/nginx/conf.d folder
Code:
server {
  listen 80;
  server_name localhost;

  client_max_body_size 128M;

  # serve media files
  location /media/ {
    alias /media/;
  }
  # pass requests for dynamic content to gunicorn
  location / {
    proxy_set_header Host $http_host;
    proxy_pass http://recipes-web:8080;
  }
}

Copy the env.template file to your docker folder and save it as .env and alter to you needs
env.template

Run the docker-compose after you finished changing everything to your needs
Code:
cd /volume1/docker/recipes
docker-compose -p "recipes" up -d
Heya,
does your setup still work? I cant get tandoor to work for the life of me. Tried tandoors own installation guide, mariushostings guide and your setup - but I only get a "connection reset" or "connection refused" error when trying to access tandoor via the specified port.
Thanks!
 
does your setup still work?
Yes it still works! Not using it much so the containers are most of time off, but yes still working.
Could you post your setup and how you configured it. Also are you using a reverse proxy e.g. NPM or the default DSM Reverse Proxy? Also post you logs.
The more info you provide the better we can help you!
 

Create an account or login to comment

You must be a member in order to leave a comment

Create account

Create an account on our community. It's easy!

Log in

Already have an account? Log in here.

Welcome to SynoForum.com!

SynoForum.com is an unofficial Synology forum for NAS owners and enthusiasts.

Registration is free, easy and fast!

Back
Top