{"id":16406694,"url":"https://github.com/arranbartish/provisioning","last_synced_at":"2025-02-23T21:23:38.713Z","repository":{"id":89567971,"uuid":"101877496","full_name":"arranbartish/provisioning","owner":"arranbartish","description":"Used to provision machines or a collection of machines","archived":false,"fork":false,"pushed_at":"2017-09-05T16:11:51.000Z","size":5,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-01-05T15:44:03.508Z","etag":null,"topics":[],"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/arranbartish.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":"2017-08-30T12:18:52.000Z","updated_at":"2017-09-04T12:10:24.000Z","dependencies_parsed_at":"2023-07-10T16:01:18.614Z","dependency_job_id":null,"html_url":"https://github.com/arranbartish/provisioning","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arranbartish%2Fprovisioning","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arranbartish%2Fprovisioning/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arranbartish%2Fprovisioning/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/arranbartish%2Fprovisioning/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/arranbartish","download_url":"https://codeload.github.com/arranbartish/provisioning/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240380638,"owners_count":19792334,"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":[],"created_at":"2024-10-11T06:10:37.468Z","updated_at":"2025-02-23T21:23:38.678Z","avatar_url":"https://github.com/arranbartish.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# provisioning\nUsed to provision machines or a collection of machines\n\n# Docker hub project\n\nhttps://hub.docker.com/r/arranbartish/provisioning/\n\n# Usage\nFor testing setup an empty VM on 10.0.2.2\n\n## VM Requirments\n\n - key based athentication with a public key in the authorized hosts\n\n## Executung machine requirements\n\n- Directory with the private key corisponding to the public key on the target machine\n- Properly configured ssh `config` file, like the some below, in the same directory. Ensure that the host, user, and ssh port actually match the target machine\n```\nHost docker-node\n    HostName 10.0.2.2\n    user arran\n    port 2222\n```\n\n## Building the container\n\n```\n$ docker build -t provisioning .\n```\n\n## Running the container as a process\n\n```\n$ docker run -v ~/.ssh:/ssh -v ~/dev/provisioning/files:/files --env-file .env --name provision provisioning\n$ docker exec -u 0 -it \u003cCONTAINER ID\u003e /bin/bash\n```\n## Execute adhoc commands through the container\n\n### Using the built image described above\n\n```\n$ docker run  --rm  -v ~/.ssh:/ssh --env-file .env provisioning \"ansible-playbook files/playbook.yml -i files/hosts \u0026\u0026 ssh docker-node 'cat hello-world.txt'\"\n```\n\n### using the latest pre-built image available on docker-hub\n\n```\n$ docker run  --rm  -v ~/.ssh:/ssh --env-file .env arranbartish/provisioning \"ansible-playbook files/playbook.yml -i files/hosts \u0026\u0026 ssh docker-node 'cat hello-world.txt'\"\n```\n\nThe above command will execute using the package \"default\" inventory and playbook in the image.\n\n### Customizing the process\n\nYou can mount custom inventory and playbooks in a volume and use them from the same image.\n\n```\n$ docker run  --rm  -v ~/.ssh:/ssh -v ~/dev/provisioning/files:/files --env-file .env arranbartish/provisioning \"ansible-playbook /files/playbook.yml -i /files/hosts \u0026\u0026 ssh docker-node 'cat hello-world.txt'\"\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farranbartish%2Fprovisioning","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Farranbartish%2Fprovisioning","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Farranbartish%2Fprovisioning/lists"}