{"id":16724994,"url":"https://github.com/meyskens/registry-usb","last_synced_at":"2026-04-02T03:00:09.862Z","repository":{"id":84515640,"uuid":"100788163","full_name":"meyskens/registry-usb","owner":"meyskens","description":"Hosting a local Docker registry on a USB drive","archived":false,"fork":false,"pushed_at":"2017-08-19T17:35:40.000Z","size":4,"stargazers_count":14,"open_issues_count":0,"forks_count":7,"subscribers_count":4,"default_branch":"master","last_synced_at":"2025-04-10T10:42:10.731Z","etag":null,"topics":["docker","localhost","registry"],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/meyskens.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2017-08-19T10:49:58.000Z","updated_at":"2024-06-05T16:32:07.000Z","dependencies_parsed_at":null,"dependency_job_id":"ec851006-9ab4-4bbb-9656-0a7fb1f48bfb","html_url":"https://github.com/meyskens/registry-usb","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/meyskens/registry-usb","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meyskens%2Fregistry-usb","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meyskens%2Fregistry-usb/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meyskens%2Fregistry-usb/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meyskens%2Fregistry-usb/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/meyskens","download_url":"https://codeload.github.com/meyskens/registry-usb/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/meyskens%2Fregistry-usb/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":31294808,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-04-02T01:43:37.129Z","status":"online","status_checked_at":"2026-04-02T02:00:08.535Z","response_time":89,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["docker","localhost","registry"],"created_at":"2024-10-12T22:47:32.556Z","updated_at":"2026-04-02T03:00:09.797Z","avatar_url":"https://github.com/meyskens.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"Docker registry on a USB Flash Drive\n====================================\n\nGot big images but no direct fiber to your laptop? No problem! Just Bring Your Own Docker Registry. This is a project used to my [DockerBook](https://eyskens.me/docker-on-the-desktop/) to store large Docker images containing Windows. After brainstorming about local registry servers [Carolyn Van Slyck](http://carolynvanslyck.com/) came on the idea to just host in on a local USB Flash drive.\n\n![Pushing a VM with Visual Studio](https://static.eyskens.me/push-win10.png)\n\n## How to setup\nThe setup consists our of 2 parts in the `docker-compose.yml`, if you have never used this I suggest to look into [\"Overview of Docker Compose\"](https://docs.docker.com/compose/overview/).\n\nThe first part is to setup the registry.  \nHere not much setup is needed. The container has 2 volumes, one contains the config files the other one the storage. The config files are quite generic and shouldn't be changed.  \nFor the 2nd volume you should change the path from `/media/usb0/` to where your USB drive is mounted, this may vary on the distro and desktop envoirement of your choise.  \nThe IP address there should not be changed unless you have a conflicting interface.\n\nThe second is the proxy.  \nShould you not want a nice domain and/or local TLS you may delete the part in the compose file and add the following to the registry part.\n```\nports:\n  - 5000:5000\n```\nWhich allows you to do `docker-compose up` and push images to `localhost:5000/`\n\nBut to me this seemed boring and bad looking. So I have set up Caddy. And an A record on a subdomain to `172.20.128.2`.\nI used a static IP to be able to use an A record on my DNS, should I be offline an entry in `/etc/hosts` will do.  \nThe Dockerfile used for Caddy is provided in `./caddy`. Since this is a private IP and I don't want my registry to be exposed to the internet I used the DNS module to verify the ownership of my domain.  \nIn my case this was Cloudflare. If you have another DNS provider you want to use you need to change `bash -s tls.dns.cloudflare` in the Dockerfile to your provided and also change the Caddy file to match the needed configuration.  \nIf you do use CloudFlare you need to set the `CLOUDFLARE_EMAIL` and `CLOUDFLARE_API_KEY` in the compose file. This way Caddy can set the required records.  \nThe last step is to change `reg.maartje.tech` which is my domain to yours. \n\nNow you'll be able to run `docker-compose up` and are ready to go!\n\n\n\n## My setup\nI am using the \"Lexar jumpdrive P20\" ([image](https://twitter.com/MaartjeME/status/898912679624146944)) since it is the fastest (for this price range) I could find. I use CloudFlare for my DNS as meantioned above. I turn the system on and off using i3-blocks. \n\n## Extra \u003c3 for i3 users\nI included my script for i3-blocks under the name `i3-bar.sh`. You can toggle the state by double clicking the bar text.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmeyskens%2Fregistry-usb","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmeyskens%2Fregistry-usb","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmeyskens%2Fregistry-usb/lists"}