volumes: tinyfilemanager_config:
Open config.php to update user access controls. By default, TinyFileManager includes two roles: and user . nano config.php Use code with caution. Locate the $auth_users array:
However, this is brittle because the file is inside the container. Better approach: Override the config file with a volume mount. tinyfilemanager docker compose
curl -o config.php https://raw.githubusercontent =.com/prasathmani/tinyfilemanager/master/config.php Use code with caution. 2. Modifying User Credentials
USER www-data
services: tinyfilemanager: image: tinyfilemanager/tinyfilemanager:latest labels: - "traefik.enable=true" - "traefik.http.routers.tfm.rule=Host( files.yourdomain.com )" - "traefik.http.routers.tfm.tls.certResolver=letsencrypt" networks: - traefik
$auth_users = [ 'admin' => '$2y$10$axZWNo7Z..0z0mP9vCg9O.3pG8VwS5I05iJc.g4t0bI6pXh2uW6C.', // Default: admin@123 'user' => '$2y$10$p8/mK8L.w6Yc8Yg/gG6gO.d5lA2pXw3O5iJc.g4t0bI6pXh2uW6C.' // Default: user@123 ]; Use code with caution. volumes: tinyfilemanager_config: Open config
In this example, the tinyfilemanager service:
By using Docker Compose, the team achieved several benefits: Locate the $auth_users array: However, this is brittle
Download the official template configuration file directly from the source repository into your project folder:
Before we begin, ensure you have: