{"id":24778416,"url":"https://github.com/hedlund/packer-pi-hole","last_synced_at":"2026-05-17T00:56:04.092Z","repository":{"id":147944000,"uuid":"328470949","full_name":"hedlund/packer-pi-hole","owner":"hedlund","description":"A script for building a Pi Hole image using Packer.","archived":false,"fork":false,"pushed_at":"2021-01-10T20:26:19.000Z","size":2,"stargazers_count":0,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-03-24T02:18:05.265Z","etag":null,"topics":["packer","packer-scripts","pi-hole","raspberry-pi","raspberrypi","raspbian"],"latest_commit_sha":null,"homepage":"","language":"Makefile","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/hedlund.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,"zenodo":null}},"created_at":"2021-01-10T20:17:23.000Z","updated_at":"2021-01-11T12:22:02.000Z","dependencies_parsed_at":null,"dependency_job_id":"ccb470ff-b7a8-427e-abb6-eda938fdaa54","html_url":"https://github.com/hedlund/packer-pi-hole","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/hedlund/packer-pi-hole","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hedlund%2Fpacker-pi-hole","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hedlund%2Fpacker-pi-hole/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hedlund%2Fpacker-pi-hole/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hedlund%2Fpacker-pi-hole/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hedlund","download_url":"https://codeload.github.com/hedlund/packer-pi-hole/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hedlund%2Fpacker-pi-hole/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":270891788,"owners_count":24663537,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2025-08-17T02:00:09.016Z","response_time":129,"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":["packer","packer-scripts","pi-hole","raspberry-pi","raspberrypi","raspbian"],"created_at":"2025-01-29T08:19:58.462Z","updated_at":"2026-05-17T00:56:04.043Z","avatar_url":"https://github.com/hedlund.png","language":"Makefile","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Packer: Pi-Hole\n\nA script for building a [Pi Hole](https://pi-hole.net/) image using \n[Packer](https://www.packer.io/).\n\n## Prerequisites\n\nFirst, [install Packer](https://www.packer.io/docs/install) on your system.\nFor Debian/Ubuntu based systems:\n\n```bash\ncurl -fsSL https://apt.releases.hashicorp.com/gpg | sudo apt-key add -\nsudo apt-add-repository \"deb [arch=amd64] https://apt.releases.hashicorp.com $(lsb_release -cs) main\"\nsudo apt-get update \u0026\u0026 sudo apt-get install packer\n```\n\nThen you need to install the [ARM image plugin](https://github.com/solo-io/packer-builder-arm-image).\nThis requires a working install of [Go](https://golang.org/doc/install).\n\n```bash\ngit clone https://github.com/solo-io/packer-builder-arm-image\ncd packer-builder-arm-image\ngo mod download\ngo build\n```\n\n\u003e There is an alternative Packer ARM plugin if you want more control:\n\u003e https://github.com/mkaczanowski/packer-builder-arm.\n\nAfter building the plugin, you need to copy the binary to a location where\nPacker can pick it up (e.g. `$HOME/.packer.d/plugins`). However, you will\nmost likely run the build a root, so keep that in mind:\n\n```bash\nsudo mkdir -p /root/packer.d/plugins/\nsudo mv packer-builder-arm-image /root/packer.d/plugins/\n```\n\nLastly, you also need to instrall `kpartx` and `qemu`:\n\n```bash\nsudo apt install kpartx qemu-user-static\n```\n\n## Building\n\nYou need to create a config file named `vars.json` which contains a bit of\nconfiguration:\n\n```json\n{\n  \"user_name\": \"\u003cuser\u003e\",\n  \"user_password\": \"\u003cpassword\u003e\",\n  \"user_public_key\": \"\u003cpublic ssh key for user\u003e\",\n  \"pi_password\": \"\u003canother password\u003e\",\n  \"pihole_web_password\": \"\u003cyet anotehr password\u003e\",\n  \"host_name\": \"piholr\",\n  \"ipv4_address\": \"10.0.0.10/24\"\n}\n```\n\n| Variable              | Description                                          |\n|-----------------------|------------------------------------------------------|\n| `user_name`           | If not empty a new user with this name will created. |\n| `user_password`       | The password for the new user.                       |\n| `user_public_key`     | The SSH public key for the new user.                 |\n| `pi_password`         | A new password for the default `pi` user.            |\n| `pihole_web_password` | The password for the Pi-hole web interface.          |\n| `host_name`           | The host name (default: `pihole`).                   |\n| `ipv4_address`        | The IPv4 address of the machine (used by Pi-hole).   |\n| `ipv6_address`        | The IPv6 address of the machine. Can be left empty.  |\n\nWhen you've created the `vars.json` file you can build the image with:\n\n```bash\nsudo make build\n```\n\nThe resulting image `output-arm-image/image` can be burned to a micro-SD card.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhedlund%2Fpacker-pi-hole","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhedlund%2Fpacker-pi-hole","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhedlund%2Fpacker-pi-hole/lists"}