{"id":20331046,"url":"https://github.com/tgallacher/ansible-macbook-setup","last_synced_at":"2026-02-09T15:09:31.498Z","repository":{"id":97478944,"uuid":"261567961","full_name":"tgallacher/ansible-macbook-setup","owner":"tgallacher","description":"🐍💻  Ansible playbook to configure and manage my Mac dev set up.","archived":false,"fork":false,"pushed_at":"2022-09-15T13:26:09.000Z","size":65,"stargazers_count":4,"open_issues_count":13,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-05-09T02:02:16.547Z","etag":null,"topics":["ansible"],"latest_commit_sha":null,"homepage":"","language":"Jinja","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tgallacher.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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":"2020-05-05T19:45:47.000Z","updated_at":"2024-01-16T01:48:12.000Z","dependencies_parsed_at":"2023-04-20T14:50:31.743Z","dependency_job_id":null,"html_url":"https://github.com/tgallacher/ansible-macbook-setup","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/tgallacher/ansible-macbook-setup","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tgallacher%2Fansible-macbook-setup","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tgallacher%2Fansible-macbook-setup/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tgallacher%2Fansible-macbook-setup/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tgallacher%2Fansible-macbook-setup/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tgallacher","download_url":"https://codeload.github.com/tgallacher/ansible-macbook-setup/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tgallacher%2Fansible-macbook-setup/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":267693799,"owners_count":24129137,"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-07-29T02:00:12.549Z","response_time":2574,"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":["ansible"],"created_at":"2024-11-14T20:18:34.978Z","updated_at":"2026-02-09T15:09:31.463Z","avatar_url":"https://github.com/tgallacher.png","language":"Jinja","funding_links":[],"categories":[],"sub_categories":[],"readme":"# MacBook Ansible Playbook\n\nAnsible playbook to configure and manage my Mac(s). A much overdue attempt to bring consistency between macbooks used for work, home, etc and to self document changes I want to keep -- and can never remember why/what I changed when I find something new.\n\n\u003e This is heavily based on and inspired by the fantastic work by [Jeff Geerling](https://github.com/geerlingguy) and his [mac-dev-playbook](https://github.com/geerlingguy/mac-dev-playbook).\n\n\u003c!-- TOC --\u003e\n\n- [Installation](#installation)\n  - [First time run](#first-time-run)\n  - [Running after updates](#running-after-updates)\n  - [Running a specific set of tagged tasks](#running-a-specific-set-of-tagged-tasks)\n- [Customising](#customising)\n- [Testing the Playbook](#testing-the-playbook)\n\n\u003c!-- /TOC --\u003e\n\n\u003ca id=\"markdown-installation\" name=\"installation\"\u003e\u003c/a\u003e\n\n## Installation\n\n\u003ca id=\"markdown-first-time-run\" name=\"first-time-run\"\u003e\u003c/a\u003e\n\n### First time run\n\nThere is a cyclic dependency here: we use Ansible to automate most of the config and setup, but that requires Python v3+, which we want to install using [Homebrew](https://brew.sh). Therefore, we need a few manual tasks first before we kick on automation wheel. To semi-automate these steps, and maintain a more up to date list, see -- and use -- `bootstrap.sh`.\n\nThe `bootstrap.sh` file will also run ansible for you!\n\n\u003ca id=\"markdown-running-after-updates\" name=\"running-after-updates\"\u003e\u003c/a\u003e\n\n### Running after updates\n\n1. Run `ansible-galaxy install -r requirements.yml`;\n1. Run `ansible-playbook -K main.yml` inside this directory. Enter your account password when prompted.\n\n\u003e Note: If some Homebrew commands fail, you might need to agree to Xcode's license or fix some other Homebrew issue. Run `brew doctor` to see if this is the case.\n\n\u003ca id=\"markdown-running-a-specific-set-of-tagged-tasks\" name=\"running-a-specific-set-of-tagged-tasks\"\u003e\u003c/a\u003e\n\n### Running a specific set of tagged tasks\n\nYou can filter which part of the provisioning process to run by specifying the set of tags using `ansible-playbook`'s `--tags` flag. The tags available:\n\n- `tools` - Taks relating to installing tooling\n- `config` - Taks relating to custom configuration of the OS\n- `ui` - Tasks affecting the OS UI\n\nExample:\n\n```sh\n$ ansible-playbook main.yml -i inventory -K --tags \"config\"\n```\n\n\u003ca id=\"markdown-customising\" name=\"customising\"\u003e\u003c/a\u003e\n\n## Customising\n\nTo see what variables exist for cusotmising the install, check the `defaults/*.yml` files or the docs for the installed ansible roles.\n\nRunning this playbook without any changes will bring in my dev setup on your mac; this is almost certainly _not_ what you're after. Instead, override the defaults by supplying any file named `config*.yml`. For example, you can customize the installed packages and apps with something like:\n\n```yaml\n# Use `homebrew_installed_packages` to override all installed formulae with your own choice\n# Use `homebrew_installed_addn_packages` to add additional formulae whilst retaining my default ones\n#\n# Same variables apply for Casks. See `defaults/homebrew.yml`\nhomebrew_installed_packages:\n  - cowsay\n  - git\n  - go\n```\n\nMy [dotfiles](https://github.com/tgallacher/dotfiles) are also installed, in addition to an `.osx` script for configuring OSX to my preference.\n\nFinally, there are a few other preferences and settings added on for various apps and services.\n\n\u003ca id=\"markdown-testing-the-playbook\" name=\"testing-the-playbook\"\u003e\u003c/a\u003e\n\n## Testing the Playbook\n\nChanges are tested in a fresh install of OSX in a VM (using VirtualBox) before being run on a new Mac. This is based [Jeff's approach](https://github.com/geerlingguy/mac-osx-virtualbox-vm), although I have curated my own instructions for this process [here](./docs/vm-testing.md).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftgallacher%2Fansible-macbook-setup","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftgallacher%2Fansible-macbook-setup","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftgallacher%2Fansible-macbook-setup/lists"}