Skip to main content

Overview

Docker

Cross-platform images are built for x86 (Intel/AMD) and ARM64 (IE Raspberry Pi)

Available Images

Repository Page

docker.io/foxxmd/komodo-import:latest

Or use the example compose.yml, found in the repo, after modifying it to fit your configuration:

compose.yml
services:
komodo-import:
image: foxxmd/komodo-import:latest
volumes:
## Mount the parent directory where all subfolders are compose projects
- /home/myUser/homelab:/filesOnServer
environment:
## Same as host directory mounted above
- HOST_DIR=/home/myUser/homelab
## where stacks are generated from. 'dir' or 'compose'
- STACKS_FROM=dir
## Komodo Server name to use for generated Stacks
- SERVER_NAME=my-cool-server

## optional
#- TZ=America/New_York
#- IMAGE_REGISTRY_PROVIDER=
#- IMAGE_REGISTRY_ACCOUNT=
#- AUTO_UPDATE=false
#- POLL_FOR_UPDATE=false
#- KOMODO_ENV_NAME=
#- COMPOSE_FILE_GLOB=
#- ENV_FILE_GLOB=
restart: no

Docker Usage Example

tip

Use the Quick Start Guide for an interactive setup!

The example scenario:

  • You have Komodo already setup
  • You have installed Periphery on a machine
    • The Komodo Server name for this machine is my-cool-server
    • The machine is currently using dockge and its projects directory looks like this:
.
└── /home/myUser/homelab/
├── immich/
│ └── compose.yaml
├── plex/
│ ├── docker-compose.yaml
│ └── .git
└── uptime-kuma/
└── compose.yaml
docker-compose.yml
services:
komodo-import:
image: foxxmd/komodo-import:latest
volumes:
- /home/myUser/homelab:/filesOnServer:ro
environment:
- TZ=America/New_York
## Komodo Server name to use for generated Stacks
- SERVER_NAME=my-cool-server
## ParentDirectory on the host use as Stack Run Directory prefix
- HOST_DIR=/home/myUser/homelab
## generate stacks from mounted directory subfolders
- STACKS_FROM=dir
restart: no
Console Output Example
docker compose up --no-log-prefix
INFO : [Init] Debug Mode: NO
INFO : [App] Version: 0.1.0
INFO : [App] Files On Server Dir ENV: /filesOnServer -> Resolved: /filesOnServer
INFO : [App] [Files On Server] Processing Stacks for 2 folders:
/filesOnServer/immich
/filesOnServer/plex
/filesOnServer/uptime-kuma
INFO : [App] [Files On Server] Compose File Glob: **/{compose,docker-compose}*.y?(a)ml
INFO : [App] [Files On Server] Env Glob: **/.env
INFO : [App] [Files On Server] [compose] Found Stack 'compose' at dir /filesOnServer/compose.yaml
WARN : [App] [Files On Server] [compose] Did not find any files patterns matching compose glob
INFO : [App] [Files On Server] [compose] Stack config complete

...

INFO : [App] [Files On Server] Built Stack configs for 3 folders
INFO : [App] Copy the text between the scissors to use as the *Resource File* contents within your Resource Sync

✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️

[[stack]]
name = "immich"

[stack.config]
server = "my-cool-server"
run_directory = "/home/myUser/homelab/immich"
files_on_host = true
auto_update = false
poll_for_updates = false
file_paths = [ "docker/docker-compose.yaml" ]

[[stack]]
name = "plex"

[stack.config]
server = "my-cool-server"
run_directory = "/home/myUser/homelab/plex"
files_on_host = true
auto_update = false
poll_for_updates = false

[[stack]]
name = "uptime-kuma"

[stack.config]
server = "my-cool-server"
run_directory = "/home/myUser/homelab/uptime-kuma"
files_on_host = true
auto_update = false
poll_for_updates = false
env_file_path = ".komodoEnv"
additional_env_files = [ ".env" ]
✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️ ✂️
INFO : [App] Done!

Copy the text between the scissors and create a new Sync Resource in Komodo

Local Installation

Nodejs

Clone this repository somewhere and then install from the working directory

git clone https://github.com/FoxxMD/komodo-import.git .
cd komodo-import
nvm use # optional, to set correct Node version
npm install
npm run docs:install && npm run build
npm run start

Usage Examples

SERVER_NAME=my-cool-server STACKS_FROM=dir MOUNT_DIR=/my/parent/folder node src/index.js