mirror of
				https://github.com/zoriya/Kyoo.git
				synced 2025-11-04 03:27:14 -05:00 
			
		
		
		
	Make prod docker-compose the default (#411)
This commit is contained in:
		
						commit
						1252016fff
					
				@ -2,7 +2,7 @@
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
1. Install docker & docker-compose
 | 
					1. Install docker & docker-compose
 | 
				
			||||||
2. Download the
 | 
					2. Download the
 | 
				
			||||||
   [`docker-compose.yml`](https://raw.githubusercontent.com/zoriya/Kyoo/master/docker-compose.prod.yml),
 | 
					   [`docker-compose.yml`](https://github.com/zoriya/kyoo/releases/latest/download/docker-compose.yml),
 | 
				
			||||||
   [`nginx.conf.template`](https://raw.githubusercontent.com/zoriya/Kyoo/master/nginx.conf.template) and
 | 
					   [`nginx.conf.template`](https://raw.githubusercontent.com/zoriya/Kyoo/master/nginx.conf.template) and
 | 
				
			||||||
   [`.env`](https://raw.githubusercontent.com/zoriya/Kyoo/master/.env.example) files
 | 
					   [`.env`](https://raw.githubusercontent.com/zoriya/Kyoo/master/.env.example) files
 | 
				
			||||||
3. Fill the `.env` file with your configuration options (and an API Key from [themoviedb.org](https://www.themoviedb.org/))
 | 
					3. Fill the `.env` file with your configuration options (and an API Key from [themoviedb.org](https://www.themoviedb.org/))
 | 
				
			||||||
@ -22,7 +22,7 @@ Those files can be put in any directory of your choice.
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
Those 3 files are:
 | 
					Those 3 files are:
 | 
				
			||||||
 | 
					
 | 
				
			||||||
- A `docker-compose.yml` (simply copy docker-compose.prod.yml from [here](https://raw.githubusercontent.com/zoriya/Kyoo/master/docker-compose.prod.yml)).
 | 
					- A `docker-compose.yml` (simply download docker-compose.yml from [the latest release](https://github.com/zoriya/kyoo/releases/latest/download/docker-compose.yml)).
 | 
				
			||||||
- A `nginx.conf.template` copied from [here](https://raw.githubusercontent.com/zoriya/Kyoo/master/nginx.conf.template).
 | 
					- A `nginx.conf.template` copied from [here](https://raw.githubusercontent.com/zoriya/Kyoo/master/nginx.conf.template).
 | 
				
			||||||
- A `.env` file that you will need to **fill**. Look at the example [.env.example](https://raw.githubusercontent.com/zoriya/Kyoo/master/.env.example)
 | 
					- A `.env` file that you will need to **fill**. Look at the example [.env.example](https://raw.githubusercontent.com/zoriya/Kyoo/master/.env.example)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
@ -50,9 +50,6 @@ unsure that your `.env` contains all the options specified in the updated `.env.
 | 
				
			|||||||
After that, you will need to update Kyoo's services. For that, open a terminal in the configuration's directory and run
 | 
					After that, you will need to update Kyoo's services. For that, open a terminal in the configuration's directory and run
 | 
				
			||||||
the command `docker-compose pull`. You are now ready to restart Kyoo, you can run `docker-compose up -d`.
 | 
					the command `docker-compose pull`. You are now ready to restart Kyoo, you can run `docker-compose up -d`.
 | 
				
			||||||
 | 
					
 | 
				
			||||||
You can also enable automatic updates via an external tool like [watchtower](https://containrrr.dev/watchtower/).
 | 
					 | 
				
			||||||
TLDR: `docker run -d --name watchtower -e WATCHTOWER_CLEANUP=true -e WATCHTOWER_POLL_INTERVAL=86400 -v /var/run/docker.sock:/var/run/docker.sock containrrr/watchtower`
 | 
					 | 
				
			||||||
 | 
					 | 
				
			||||||
# Uninstalling
 | 
					# Uninstalling
 | 
				
			||||||
 | 
					
 | 
				
			||||||
To uninstall Kyoo, you need to open a terminal in the configuration's directory and run `docker-compose down`. This will
 | 
					To uninstall Kyoo, you need to open a terminal in the configuration's directory and run `docker-compose down`. This will
 | 
				
			||||||
 | 
				
			|||||||
@ -1,10 +1,10 @@
 | 
				
			|||||||
x-transcoder: &transcoder-base
 | 
					x-transcoder: &transcoder-base
 | 
				
			||||||
  image: zoriya/kyoo_transcoder:latest
 | 
					  build: ./transcoder
 | 
				
			||||||
  networks:
 | 
					  networks:
 | 
				
			||||||
    default:
 | 
					    default:
 | 
				
			||||||
      aliases:
 | 
					      aliases:
 | 
				
			||||||
        - transcoder
 | 
					        - transcoder
 | 
				
			||||||
  restart: unless-stopped
 | 
					  restart: on-failure
 | 
				
			||||||
  env_file:
 | 
					  env_file:
 | 
				
			||||||
    - ./.env
 | 
					    - ./.env
 | 
				
			||||||
  volumes:
 | 
					  volumes:
 | 
				
			||||||
@ -14,9 +14,8 @@ x-transcoder: &transcoder-base
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
services:
 | 
					services:
 | 
				
			||||||
  back:
 | 
					  back:
 | 
				
			||||||
    image: zoriya/kyoo_back:latest
 | 
					    build: ./back
 | 
				
			||||||
    restart: unless-stopped
 | 
					    restart: on-failure
 | 
				
			||||||
    cpus: 1.5
 | 
					 | 
				
			||||||
    env_file:
 | 
					    env_file:
 | 
				
			||||||
      - ./.env
 | 
					      - ./.env
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
@ -32,7 +31,9 @@ services:
 | 
				
			|||||||
      - kyoo:/kyoo
 | 
					      - kyoo:/kyoo
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  migrations:
 | 
					  migrations:
 | 
				
			||||||
    image: zoriya/kyoo_migrations:latest
 | 
					    build:
 | 
				
			||||||
 | 
					      context: ./back
 | 
				
			||||||
 | 
					      dockerfile: Dockerfile.migrations
 | 
				
			||||||
    restart: "no"
 | 
					    restart: "no"
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
      postgres:
 | 
					      postgres:
 | 
				
			||||||
@ -41,14 +42,14 @@ services:
 | 
				
			|||||||
      - ./.env
 | 
					      - ./.env
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  front:
 | 
					  front:
 | 
				
			||||||
    image: zoriya/kyoo_front:latest
 | 
					    build: ./front
 | 
				
			||||||
    restart: unless-stopped
 | 
					    restart: on-failure
 | 
				
			||||||
    environment:
 | 
					    environment:
 | 
				
			||||||
      - KYOO_URL=${KYOO_URL:-http://back:5000}
 | 
					      - KYOO_URL=${KYOO_URL:-http://back:5000}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  scanner:
 | 
					  scanner:
 | 
				
			||||||
    image: zoriya/kyoo_scanner:latest
 | 
					    build: ./scanner
 | 
				
			||||||
    restart: unless-stopped
 | 
					    restart: on-failure
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
      back:
 | 
					      back:
 | 
				
			||||||
        condition: service_healthy
 | 
					        condition: service_healthy
 | 
				
			||||||
@ -60,7 +61,7 @@ services:
 | 
				
			|||||||
      - ${LIBRARY_ROOT}:/video:ro
 | 
					      - ${LIBRARY_ROOT}:/video:ro
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  matcher:
 | 
					  matcher:
 | 
				
			||||||
    image: zoriya/kyoo_scanner:latest
 | 
					    build: ./scanner
 | 
				
			||||||
    command: matcher
 | 
					    command: matcher
 | 
				
			||||||
    restart: unless-stopped
 | 
					    restart: unless-stopped
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
@ -72,7 +73,7 @@ services:
 | 
				
			|||||||
      - KYOO_URL=${KYOO_URL:-http://back:5000}
 | 
					      - KYOO_URL=${KYOO_URL:-http://back:5000}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  autosync:
 | 
					  autosync:
 | 
				
			||||||
    image: zoriya/kyoo_autosync:latest
 | 
					    build: ./autosync
 | 
				
			||||||
    restart: on-failure
 | 
					    restart: on-failure
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
      rabbitmq:
 | 
					      rabbitmq:
 | 
				
			||||||
@ -115,7 +116,7 @@ services:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  ingress:
 | 
					  ingress:
 | 
				
			||||||
    image: nginx
 | 
					    image: nginx
 | 
				
			||||||
    restart: unless-stopped
 | 
					    restart: on-failure
 | 
				
			||||||
    environment:
 | 
					    environment:
 | 
				
			||||||
      - PORT=8901
 | 
					      - PORT=8901
 | 
				
			||||||
      - FRONT_URL=http://front:8901
 | 
					      - FRONT_URL=http://front:8901
 | 
				
			||||||
@ -130,7 +131,7 @@ services:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  postgres:
 | 
					  postgres:
 | 
				
			||||||
    image: postgres:15
 | 
					    image: postgres:15
 | 
				
			||||||
    restart: unless-stopped
 | 
					    restart: on-failure
 | 
				
			||||||
    env_file:
 | 
					    env_file:
 | 
				
			||||||
      - ./.env
 | 
					      - ./.env
 | 
				
			||||||
    volumes:
 | 
					    volumes:
 | 
				
			||||||
@ -143,7 +144,7 @@ services:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  meilisearch:
 | 
					  meilisearch:
 | 
				
			||||||
    image: getmeili/meilisearch:v1.4
 | 
					    image: getmeili/meilisearch:v1.4
 | 
				
			||||||
    restart: unless-stopped
 | 
					    restart: on-failure
 | 
				
			||||||
    volumes:
 | 
					    volumes:
 | 
				
			||||||
      - search:/meili_data
 | 
					      - search:/meili_data
 | 
				
			||||||
    environment:
 | 
					    environment:
 | 
				
			||||||
@ -1,10 +1,10 @@
 | 
				
			|||||||
x-transcoder: &transcoder-base
 | 
					x-transcoder: &transcoder-base
 | 
				
			||||||
  build: ./transcoder
 | 
					  image: zoriya/kyoo_transcoder:latest
 | 
				
			||||||
  networks:
 | 
					  networks:
 | 
				
			||||||
    default:
 | 
					    default:
 | 
				
			||||||
      aliases:
 | 
					      aliases:
 | 
				
			||||||
        - transcoder
 | 
					        - transcoder
 | 
				
			||||||
  restart: on-failure
 | 
					  restart: unless-stopped
 | 
				
			||||||
  env_file:
 | 
					  env_file:
 | 
				
			||||||
    - ./.env
 | 
					    - ./.env
 | 
				
			||||||
  volumes:
 | 
					  volumes:
 | 
				
			||||||
@ -14,8 +14,9 @@ x-transcoder: &transcoder-base
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
services:
 | 
					services:
 | 
				
			||||||
  back:
 | 
					  back:
 | 
				
			||||||
    build: ./back
 | 
					    image: zoriya/kyoo_back:latest
 | 
				
			||||||
    restart: on-failure
 | 
					    restart: unless-stopped
 | 
				
			||||||
 | 
					    cpus: 1.5
 | 
				
			||||||
    env_file:
 | 
					    env_file:
 | 
				
			||||||
      - ./.env
 | 
					      - ./.env
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
@ -31,9 +32,7 @@ services:
 | 
				
			|||||||
      - kyoo:/kyoo
 | 
					      - kyoo:/kyoo
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  migrations:
 | 
					  migrations:
 | 
				
			||||||
    build:
 | 
					    image: zoriya/kyoo_migrations:latest
 | 
				
			||||||
      context: ./back
 | 
					 | 
				
			||||||
      dockerfile: Dockerfile.migrations
 | 
					 | 
				
			||||||
    restart: "no"
 | 
					    restart: "no"
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
      postgres:
 | 
					      postgres:
 | 
				
			||||||
@ -42,14 +41,14 @@ services:
 | 
				
			|||||||
      - ./.env
 | 
					      - ./.env
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  front:
 | 
					  front:
 | 
				
			||||||
    build: ./front
 | 
					    image: zoriya/kyoo_front:latest
 | 
				
			||||||
    restart: on-failure
 | 
					    restart: unless-stopped
 | 
				
			||||||
    environment:
 | 
					    environment:
 | 
				
			||||||
      - KYOO_URL=${KYOO_URL:-http://back:5000}
 | 
					      - KYOO_URL=${KYOO_URL:-http://back:5000}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  scanner:
 | 
					  scanner:
 | 
				
			||||||
    build: ./scanner
 | 
					    image: zoriya/kyoo_scanner:latest
 | 
				
			||||||
    restart: on-failure
 | 
					    restart: unless-stopped
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
      back:
 | 
					      back:
 | 
				
			||||||
        condition: service_healthy
 | 
					        condition: service_healthy
 | 
				
			||||||
@ -61,7 +60,7 @@ services:
 | 
				
			|||||||
      - ${LIBRARY_ROOT}:/video:ro
 | 
					      - ${LIBRARY_ROOT}:/video:ro
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  matcher:
 | 
					  matcher:
 | 
				
			||||||
    build: ./scanner
 | 
					    image: zoriya/kyoo_scanner:latest
 | 
				
			||||||
    command: matcher
 | 
					    command: matcher
 | 
				
			||||||
    restart: unless-stopped
 | 
					    restart: unless-stopped
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
@ -73,7 +72,7 @@ services:
 | 
				
			|||||||
      - KYOO_URL=${KYOO_URL:-http://back:5000}
 | 
					      - KYOO_URL=${KYOO_URL:-http://back:5000}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
  autosync:
 | 
					  autosync:
 | 
				
			||||||
    build: ./autosync
 | 
					    image: zoriya/kyoo_autosync:latest
 | 
				
			||||||
    restart: on-failure
 | 
					    restart: on-failure
 | 
				
			||||||
    depends_on:
 | 
					    depends_on:
 | 
				
			||||||
      rabbitmq:
 | 
					      rabbitmq:
 | 
				
			||||||
@ -116,7 +115,7 @@ services:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  ingress:
 | 
					  ingress:
 | 
				
			||||||
    image: nginx
 | 
					    image: nginx
 | 
				
			||||||
    restart: on-failure
 | 
					    restart: unless-stopped
 | 
				
			||||||
    environment:
 | 
					    environment:
 | 
				
			||||||
      - PORT=8901
 | 
					      - PORT=8901
 | 
				
			||||||
      - FRONT_URL=http://front:8901
 | 
					      - FRONT_URL=http://front:8901
 | 
				
			||||||
@ -131,7 +130,7 @@ services:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  postgres:
 | 
					  postgres:
 | 
				
			||||||
    image: postgres:15
 | 
					    image: postgres:15
 | 
				
			||||||
    restart: on-failure
 | 
					    restart: unless-stopped
 | 
				
			||||||
    env_file:
 | 
					    env_file:
 | 
				
			||||||
      - ./.env
 | 
					      - ./.env
 | 
				
			||||||
    volumes:
 | 
					    volumes:
 | 
				
			||||||
@ -144,7 +143,7 @@ services:
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
  meilisearch:
 | 
					  meilisearch:
 | 
				
			||||||
    image: getmeili/meilisearch:v1.4
 | 
					    image: getmeili/meilisearch:v1.4
 | 
				
			||||||
    restart: on-failure
 | 
					    restart: unless-stopped
 | 
				
			||||||
    volumes:
 | 
					    volumes:
 | 
				
			||||||
      - search:/meili_data
 | 
					      - search:/meili_data
 | 
				
			||||||
    environment:
 | 
					    environment:
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user