{"id":37682618,"url":"https://github.com/outscale/k8s-image-preloader","last_synced_at":"2026-01-16T12:27:47.112Z","repository":{"id":318899597,"uuid":"1071462854","full_name":"outscale/k8s-image-preloader","owner":"outscale","description":"Preloading images to a Kubernetes node to reduce startup duration \u0026 allow running nodes without Internet access","archived":false,"fork":false,"pushed_at":"2026-01-14T01:02:26.000Z","size":34,"stargazers_count":0,"open_issues_count":4,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-01-14T04:56:29.151Z","etag":null,"topics":["maturity-sandbox"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/outscale.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":".github/CODEOWNERS","security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-07T11:38:34.000Z","updated_at":"2026-01-13T16:35:00.000Z","dependencies_parsed_at":null,"dependency_job_id":"9efa2e96-6c79-4b3f-9f7f-377cde00c28c","html_url":"https://github.com/outscale/k8s-image-preloader","commit_stats":null,"previous_names":["outscale/k8s-image-preloader"],"tags_count":1,"template":false,"template_full_name":null,"purl":"pkg:github/outscale/k8s-image-preloader","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/outscale%2Fk8s-image-preloader","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/outscale%2Fk8s-image-preloader/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/outscale%2Fk8s-image-preloader/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/outscale%2Fk8s-image-preloader/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/outscale","download_url":"https://codeload.github.com/outscale/k8s-image-preloader/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/outscale%2Fk8s-image-preloader/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28478650,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-01-16T11:59:17.896Z","status":"ssl_error","status_checked_at":"2026-01-16T11:55:55.838Z","response_time":107,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"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":["maturity-sandbox"],"created_at":"2026-01-16T12:27:46.468Z","updated_at":"2026-01-16T12:27:47.101Z","avatar_url":"https://github.com/outscale.png","language":"Go","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Kubernetes image preloader\n\n[![Project Sandbox](https://docs.outscale.com/fr/userguide/_images/Project-Sandbox-yellow.svg)](https://docs.outscale.com/en/userguide/Open-Source-Projects.html) [![](https://dcbadge.limes.pink/api/server/HUVtY5gT6s?style=flat\u0026theme=default-inverted)](https://discord.gg/HUVtY5gT6s)\n\n\u003cp align=\"center\"\u003e\n  \u003cimg alt=\"Kubernetes Logo\" src=\"https://upload.wikimedia.org/wikipedia/commons/3/39/Kubernetes_logo_without_workmark.svg\" width=\"120px\"\u003e\n\u003c/p\u003e\n\n---\n\n## 🌐 Links\n\n- Documentation: \u003chttps://docs.outscale.com/en/\u003e\n- Project website: \u003chttps://github.com/outscale/\u003cproject-name\u003e\u003e\n- Join our community on [Discord](https://discord.gg/HUVtY5gT6s)\n\n---\n\n## 📄 Table of Contents\n\n- [Overview](#-overview)\n- [Requirements](#-requirements)\n- [Usage](#-usage)\n- [License](#-license)\n- [Contributing](#-contributing)\n\n---\n\n## 🧭 Overview\n\n**Kubernetes image preloader** is a tool that allows you to create a snapshot of images that can be preloaded onto new Kubernetes nodes.\n\nIt enables faster startup times and allows nodes to run without internet access.\n\n---\n\n## ✅ Requirements\n\n- A Kubernetes cluster running containerd,\n- A CSI driver with snapshotting enabled.\n\n---\n\n## 🚀 Usage\n\n### Creating a snapshot\n\n```bash\nkubectl apply -f example/example.yaml\n```\n\nThis will:\n- list all images present in the local containerd cache,\n- list all images used by pods/cronjobs on the local cluster and not present in the cache,\n- refetch all images to the local containerd cache,\n- export all images to a PVC,\n- copy a restore script to the PVC,\n- take a CSI snapshot of the volume.\n\n\u003e By default, containerd purges some layers, pulling all images again is required before exporting images.\n\n### Preloading images\n\nTo preload the images stored on the snapshot, you will need to attach a volume based on the snapshot to the node VM.\n\nUsing cluster api, in a OscMachineTemplate resource:\n```yaml\n        vm:\n          [...]\n        volumes:\n        - device: /dev/xvdb\n          size: 2\n          type: gp2\n          fromSnapshot: snap-xxx\n```\n\n\u003e This requires CAPOSC v1.2.0 or later.\n\nAnd preload images in the KubeadmConfigTemplate/KubeadmControlPlane resources:\n```yaml\n  spec:\n    joinConfiguration:\n      [...]\n    mounts:\n      - - xvdb\n        - /preload\n        - ext4\n        - auto,exec,ro\n    preKubeadmCommands:\n      - /preload/restore.sh\n```\n\n### Manual use\n\nYou will need to run:\n* `preloader export` to export images to the volume,\n* `preloader snapshot` to create a snapshot of the volume,\n* `ctr images import` to import each image.\n\n### preloader export flags\n\n```bash\nExport a list of images to a path\n\nBy default, fetches the list of all images from the local cluster,\nreading the local containerd cache and the list of pods/cronjobs,\nand exports all images found to path.\n\nUsage:\n  preloader export [flags]\n\nAliases:\n  export, e\n\nFlags:\n      --cache-only          Only list images present in local cache, do not list pods\n      --exclude strings     Prefixes to skip from the list\n      --force-pull          Force an image pull before exporting\n  -h, --help                help for export\n      --no-restore-script   Do not copy restore script to the volume\n      --stdin               Fetch image list from stdin instead of the local cluster\n      --to string           Path to snapshot volume (default \"/snapshot\")\n\nGlobal Flags:\n      --ctr-flags string   ctr flags (default \"-a /var/run/containerd/containerd.sock\")\n      --ctr-path string    ctr binary path (default \"/usr/local/bin/ctr\")\n      --debug              log ctr command output\n```\n\n### preloader snapshot flags\n\n```bash\nCreate a VolumeSnapshot from the PVC storing exports of images.\n\nUsage:\n  preloader snapshot [flags]\n\nAliases:\n  snapshot, s\n\nFlags:\n      --class string       VolumeSnapshotClass to use (required)\n  -h, --help               help for snapshot\n      --name string        Name of the VolumeSnapshot to create (required)\n      --namespace string   Namespace of the VolumeSnapshot to create (required)\n      --pvc string         PVC to snashot (required)\n\nGlobal Flags:\n      --ctr-flags string   ctr flags (default \"-a /var/run/containerd/containerd.sock\")\n      --ctr-path string    ctr binary path (default \"/usr/local/bin/ctr\")\n      --debug              log ctr command output\n```\n\n---\n\n## 📜 License\n\n**Kubernetes image preloader** is released under the BSD 3-Clause license.\n\n© 2025 Outscale SAS\n\nSee [LICENSE](./LICENSE) for full details.\n\n---\n\n## 🤝 Contributing\n\nWe welcome contributions!\n\nPlease read our [Contributing Guidelines](CONTRIBUTING.md) and [Code of Conduct](CODE_OF_CONDUCT.md) before submitting a pull request.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foutscale%2Fk8s-image-preloader","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foutscale%2Fk8s-image-preloader","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foutscale%2Fk8s-image-preloader/lists"}