{"id":15059144,"url":"https://github.com/mrlesmithjr/packer-templates","last_synced_at":"2025-08-21T00:31:06.713Z","repository":{"id":3738762,"uuid":"42200370","full_name":"mrlesmithjr/packer-templates","owner":"mrlesmithjr","description":null,"archived":false,"fork":false,"pushed_at":"2023-05-30T13:19:30.000Z","size":825,"stargazers_count":138,"open_issues_count":11,"forks_count":28,"subscribers_count":15,"default_branch":"master","last_synced_at":"2024-12-07T19:11:25.245Z","etag":null,"topics":["debian","fedora","opensuse","packer","packer-template","redhat","ubuntu","vagrant","virtualbox"],"latest_commit_sha":null,"homepage":null,"language":"Shell","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/mrlesmithjr.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE.md","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2015-09-09T19:36:38.000Z","updated_at":"2024-08-12T21:56:19.000Z","dependencies_parsed_at":"2023-07-05T19:34:27.238Z","dependency_job_id":null,"html_url":"https://github.com/mrlesmithjr/packer-templates","commit_stats":{"total_commits":439,"total_committers":5,"mean_commits":87.8,"dds":0.06605922551252852,"last_synced_commit":"4b50b02a4af7888370af824d773b31b4fc96e44d"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrlesmithjr%2Fpacker-templates","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrlesmithjr%2Fpacker-templates/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrlesmithjr%2Fpacker-templates/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/mrlesmithjr%2Fpacker-templates/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/mrlesmithjr","download_url":"https://codeload.github.com/mrlesmithjr/packer-templates/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":230471175,"owners_count":18231193,"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","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":["debian","fedora","opensuse","packer","packer-template","redhat","ubuntu","vagrant","virtualbox"],"created_at":"2024-09-24T22:38:32.456Z","updated_at":"2024-12-19T17:09:09.611Z","avatar_url":"https://github.com/mrlesmithjr.png","language":"Shell","funding_links":["https://www.buymeacoffee.com/mrlesmithjr"],"categories":[],"sub_categories":[],"readme":"\u003c!-- START doctoc generated TOC please keep comment here to allow auto update --\u003e\n\u003c!-- DON'T EDIT THIS SECTION, INSTEAD RE-RUN doctoc TO UPDATE --\u003e\n\n**Table of Contents** _generated with [DocToc](https://github.com/thlorenz/doctoc)_\n\n- [packer-templates](#packer-templates)\n  - [Purpose](#purpose)\n  - [Information](#information)\n  - [Requirements](#requirements)\n    - [Software](#software)\n  - [Usage](#usage)\n    - [Building a box](#building-a-box)\n      - [Select distro](#select-distro)\n      - [Build distro](#build-distro)\n    - [Testing a box](#testing-a-box)\n      - [Add box to Vagrant](#add-box-to-vagrant)\n      - [Create Vagrantfile](#create-vagrantfile)\n      - [Spin it up](#spin-it-up)\n      - [Test it out](#test-it-out)\n      - [Tear it down](#tear-it-down)\n    - [Cleaning up](#cleaning-up)\n    - [Using pre-built and ready for consumption Vagrant templates](#using-pre-built-and-ready-for-consumption-vagrant-templates)\n  - [License](#license)\n  - [Author Information](#author-information)\n\n\u003c!-- END doctoc generated TOC please keep comment here to allow auto update --\u003e\n\n# packer-templates\n\n## Purpose\n\nThis repository is for maintaining my personal\n[Vagrant Box Templates](https://github.com/mrlesmithjr/vagrant-box-templates)\nusing [Packer](https://www.packer.io).\n\n## Information\n\nAll builds are based on the following providers:\n\n- [virtualbox](https://www.virtualbox.org)\n- [vmware_desktop](https://www.vmware.com)\n\n- You can find my collection of builds [here](https://app.vagrantup.com/mrlesmithjr)\n\n\u003e NOTE: All builds are base builds and follow the Vagrant [guidelines](https://www.vagrantup.com/docs/boxes/base.html) of how a Vagrant\n\u003e box should be built.\n\n## Requirements\n\nAll of my Packer templates are configured to upload to Vagrant Cloud after a successful build has been executed. In order to upload a box version to Vagrant Cloud, you will need to create a `private_vars.json` file in the root of this repo with the following info:\n\n```json\n{\n  \"vagrant_cloud_token\": \"Your Vagrant Cloud private API token\",\n  \"vagrant_cloud_username\": \"Your Vagrant Cloud username\"\n}\n```\n\nIf you do not want this functionality, you will need to edit the respective template within the distro folder and remove the following:\n\n```json\n{\n  \"type\": \"vagrant-cloud\",\n  \"box_tag\": \"{{ user `box_tag` }}\",\n  \"access_token\": \"{{ user `vagrant_cloud_token` }}\",\n  \"version\": \"{{ timestamp }}\"\n}\n```\n\n### Software\n\n- [Packer](https://www.packer.io)\n- [Virtualbox](https://www.virtualbox.org)\n\n## Usage\n\n### Building a box\n\nTo build a [Vagrant](https://www.vagrantup.com) box with [Packer](https://packer.io)\nfor [Virtualbox](https://www.virtualbox.org):\n\n#### Select distro\n\nChoose which distro you are interested in building.\n\n#### Build distro\n\n\u003e NOTE: This example we will have chosen Ubuntu Xenial\n\n```bash\ncd Ubuntu/xenial64/server\npacker build -var-file=../../../private_vars.json -var-file=ubuntu1604.json ../../ubuntu-server.json\n```\n\nNow watch your build kick off and run through the building process. Once it has\ncompleted you will be ready to test it out.\n\n### Testing a box\n\nOnce your build has completed you are ready to test it out.\n\n#### Add box to Vagrant\n\n\u003e Note: The number at the end is the epoch time of the build. Replace this accordingly.\n\n```bash\ncd Ubuntu/xenial64/server\nvagrant box add xenial64-server-packer-template-virtualbox-1542509766 xenial64-server-packer-template-virtualbox-1542509766.box\n```\n\n#### Create Vagrantfile\n\n```bash\ncd ~\nmkdir -p packer/vagrant/xenial64-server\ncd packer/vagrant/xenial64-server\nvagrant init xenial64-server-packer-template-virtualbox-1542509766\n```\n\n#### Spin it up\n\n```bash\nvagrant up\n```\n\n#### Test it out\n\n```bash\nvagrant ssh\n```\n\nNow do some basic tests to validate all is good.\n\n#### Tear it down\n\n```bash\nvagrant destroy -f\n```\n\n### Cleaning up\n\nWhen you need to clean up any of the lingering files/folers generated during\nbuilding, you can execute the [cleanup_builds.sh](cleanup_builds.sh) script.\n\n### Using pre-built and ready for consumption Vagrant templates\n\nThe majority of these templates are used to populate my [vagrant-box-templates](https://github.com/mrlesmithjr/vagrant-box-templates) repo. I would highly\nrecommend leveraging this repo for testing and etc.\n\n## License\n\nMIT\n\n## Author Information\n\nLarry Smith Jr.\n\n- [@mrlesmithjr](https://www.twitter.com/mrlesmithjr)\n- [EverythingShouldBeVirtual](http://everythingshouldbevirtual.com)\n- [mrlesmithjr@gmail.com](mailto:mrlesmithjr@gmail.com)\n\n\u003ca href=\"https://www.buymeacoffee.com/mrlesmithjr\" target=\"_blank\"\u003e\u003cimg src=\"https://cdn.buymeacoffee.com/buttons/v2/default-yellow.png\" alt=\"Buy Me A Coffee\" style=\"height: 60px !important;width: 217px !important;\" \u003e\u003c/a\u003e\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmrlesmithjr%2Fpacker-templates","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fmrlesmithjr%2Fpacker-templates","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fmrlesmithjr%2Fpacker-templates/lists"}