Create in less than 5 minutes an Object Storage with local files exposed via HTTPS public URL. In this tutorial I use Docker to quickly run MinIO server, and ngrok to easily share files from local machine without messing with DNS and firewall settings.
docker run --rm -p 9000:9000 \
-v /tmp/local-data:/data \
-e "MINIO_ACCESS_KEY=EXAMPLE_ACCESS_KEY" \
-e "MINIO_SECRET_KEY=EXAMPLE_SECRET_KEY" \
minio/minio server /data
./ngrok http 9000
Read following step by step guide for explanations ...
- Download link: https://ngrok.com/download
- Authenticate yourself to ngrok
- Run following command over dowloaded
ngrok
binary file
./ngrok authtoke XXXXXX
Where XXXXXX
is your account auth token. More on ngrok doc
mkdir /tmp/local-data
docker run --rm -p 9000:9000 \
-v /tmp/local-data:/data \
-e "MINIO_ACCESS_KEY=EXAMPLE_ACCESS_KEY" \
-e "MINIO_SECRET_KEY=EXAMPLE_SECRET_KEY" \
minio/minio server /data
- NB : Replace
EXAMPLE_ACCESS_KEY
/EXAMPLE_SECRET_KEY
with our more secure values. - NB : Replace
/tmp/data
with path of directory where you put files to share
Test using MinIO Browser:
Point your web browser to http://127.0.0.1:9000 to ensure your server has started successfully.
From your web browser, go to http://127.0.0.1:9000, enter your EXAMPLE_ACCESS_KEY
+ EXAMPLE_SECRET_KEY
(provided to server on previous step) as athentication credentials.
When you are connected on MinIO web app, create a bucket ex: bucket01
Expose the MinIO server which is running on port 9000 by runnin following CMD :
cd /to-dir/of-ngrok/downloaded-file
./ngrok http 9000
The command will display a generated url like https://6441f740aac1.ngrok.io
wich exposed the local MinIO web server.
NOTICE : You can replace ngrok with altenative solutiions like localtunnel
- MinIO : https://min.io
- Ngrok : https://ngrok.com
- Docker: https://www.docker.com
Hi @mikamboo, great work!
I want to combine ngrok service and minio in single docker-compose file. I'm try to archive that, but I got error:
This is my docker-compose.yml file:
This is my ngrok.yml config file which is in the same folder with docker-compose:
I guess the error is because of networking in docker, I'll learn more about that and may update the comment in the future~~ But if you know how to fix that please reply to this comment :v
Have a good day~