Deploying Mikochi
Introduction
Mikochi is a minimalist, self-hosted remote file browser that provides a clean and fast interface for managing files on your server. Built with Go for the backend and a modern JavaScript frontend, Mikochi focuses on simplicity and speed.
Unlike feature-heavy file managers, Mikochi does the essentials well: browse directories, upload files, download files, and stream media. Its lightweight nature makes it perfect for deployment alongside other services that need file management.
Key highlights of Mikochi:
- Minimalist Design: Clean, distraction-free interface
- Fast Performance: Written in Go for speed and efficiency
- File Upload: Drag-and-drop file uploads
- Media Streaming: Stream video and audio files directly
- Image Preview: View images without downloading
- Search: Find files quickly across directories
- Mobile Friendly: Responsive design works on any device
- Single Binary: Easy deployment with no dependencies
- Authentication: Basic authentication for security
- 100% Open Source: MIT licensed
This guide walks through deploying Mikochi on Klutch.sh using Docker, configuring access, and managing your files remotely.
Why Deploy Mikochi on Klutch.sh
Deploying Mikochi on Klutch.sh provides several advantages:
Remote File Access: Access your files from anywhere with a web browser.
Simplified Deployment: Klutch.sh handles container deployment automatically.
Persistent Storage: Files survive restarts and redeployments.
HTTPS by Default: Secure file access with automatic SSL.
Lightweight: Minimal resource usage means lower costs.
Custom Domains: Access files from your own domain.
Prerequisites
Before deploying Mikochi on Klutch.sh, ensure you have:
- A Klutch.sh account
- A GitHub account with a repository for your configuration
- Basic familiarity with Docker
Understanding Mikochi Architecture
Mikochi has a simple architecture:
Go Backend: Serves files and handles API requests.
JavaScript Frontend: Single-page application for the file browser.
File System: Direct access to the mounted directory.
Authentication: Basic HTTP authentication layer.
Preparing Your Repository
Create a GitHub repository for your Mikochi deployment.
Repository Structure
mikochi-deploy/├── Dockerfile├── README.md└── .dockerignoreCreating the Dockerfile
Create a Dockerfile in the root of your repository:
FROM ghcr.io/zer0tonin/mikochi:latest
# Set environment variablesENV DATA_DIR=/dataENV USERNAME=${MIKOCHI_USERNAME:-admin}ENV PASSWORD=${MIKOCHI_PASSWORD}
# Expose the web interfaceEXPOSE 8080
# Health checkHEALTHCHECK --interval=30s --timeout=10s --start-period=10s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://localhost:8080/ || exit 1Advanced Dockerfile
For additional configuration:
FROM ghcr.io/zer0tonin/mikochi:latest
# Environment variablesENV DATA_DIR=/dataENV USERNAME=${MIKOCHI_USERNAME:-admin}ENV PASSWORD=${MIKOCHI_PASSWORD}
# Hostname for the applicationENV HOST=0.0.0.0ENV PORT=8080
# JWT secret for session tokensENV JWT_SECRET=${MIKOCHI_JWT_SECRET}
# Expose portEXPOSE 8080
# Health checkHEALTHCHECK --interval=30s --timeout=10s --start-period=10s --retries=3 \ CMD wget --no-verbose --tries=1 --spider http://localhost:8080/ || exit 1Environment Variables Reference
| Variable | Required | Default | Description |
|---|---|---|---|
DATA_DIR | No | /data | Root directory for file browsing |
USERNAME | No | admin | Authentication username |
PASSWORD | Yes | - | Authentication password |
HOST | No | 0.0.0.0 | Server bind address |
PORT | No | 8080 | Server port |
JWT_SECRET | No | random | Secret for JWT tokens |
Deploying Mikochi on Klutch.sh
- Select HTTP as the traffic type
- Set the internal port to 8080
Generate a Secure Password
Create a strong password for authentication:
openssl rand -base64 24Push Your Repository to GitHub
Initialize and push your repository:
git initgit add Dockerfile .dockerignore README.mdgit commit -m "Initial Mikochi deployment configuration"git remote add origin https://github.com/yourusername/mikochi-deploy.gitgit push -u origin mainCreate a New Project on Klutch.sh
Navigate to the Klutch.sh dashboard and create a new project named “mikochi” or “file-browser”.
Create a New App
Within your project, create a new app. Connect your GitHub account and select the repository containing your Dockerfile.
Configure HTTP Traffic
In the deployment settings:
Set Environment Variables
Add the following environment variables:
| Variable | Value |
|---|---|
MIKOCHI_USERNAME | Your username |
MIKOCHI_PASSWORD | Your secure password |
MIKOCHI_JWT_SECRET | Random string for JWT |
Attach Persistent Volumes
Add storage for your files:
| Mount Path | Recommended Size | Purpose |
|---|---|---|
/data | Varies | Your file storage |
Deploy Your Application
Click Deploy to start the build process.
Access Mikochi
Once deployed, access your file browser at https://your-app-name.klutch.sh.
Using Mikochi
Browsing Files
Navigate your file structure:
- Log in with your credentials
- Click folders to navigate
- Use breadcrumbs to go back
- Click the home icon to return to root
Uploading Files
Add files to your storage:
- Navigate to the target directory
- Drag files onto the browser window
- Or click the upload button
- Monitor upload progress
Downloading Files
Retrieve files from storage:
- Navigate to the file
- Click the download icon
- File downloads to your device
Streaming Media
View and play media directly:
- Click video files to stream
- Click audio files to play
- Click images to preview
Searching
Find files quickly:
- Use the search bar
- Enter filename or partial match
- Results update as you type
File Organization
Directory Structure
Organize files logically:
/data/├── Documents/│ ├── Work/│ └── Personal/├── Media/│ ├── Photos/│ ├── Videos/│ └── Music/└── Backups/Best Practices
- Use consistent naming conventions
- Create logical folder hierarchies
- Clean up unused files regularly
- Monitor storage usage
Security Considerations
Strong Credentials
Protect your file access:
- Use a strong, unique password
- Consider changing credentials periodically
- Don’t share credentials unnecessarily
Access Control
Mikochi provides single-user authentication:
- All authenticated users have full access
- Consider network-level restrictions for sensitive files
- Use HTTPS (provided by Klutch.sh)
Integration Ideas
File Sharing
Use Mikochi alongside other services:
- Share files between applications
- Provide file storage for web apps
- Manage media library files
Backup Access
Access backup files remotely:
- Browse backup archives
- Retrieve specific files
- Verify backup contents
Troubleshooting
Cannot Login
- Verify username and password are correct
- Check environment variables are set
- Review container logs
Upload Fails
- Check available storage space
- Verify write permissions
- Check file size limits
Slow Performance
- Allocate more resources
- Reduce concurrent operations
- Check network connectivity
Additional Resources
Conclusion
Deploying Mikochi on Klutch.sh gives you a fast, minimalist file browser for remote file management. With its clean interface, media streaming, and simple authentication, Mikochi provides essential file access without unnecessary complexity.
Access your files from anywhere with Mikochi on Klutch.sh.