{"id":17397820,"url":"https://github.com/bltavares/kickstart","last_synced_at":"2025-04-15T04:23:46.602Z","repository":{"id":14364733,"uuid":"17074562","full_name":"bltavares/kickstart","owner":"bltavares","description":"Agentless configuration manager in Bash","archived":false,"fork":false,"pushed_at":"2023-09-21T03:23:18.000Z","size":90,"stargazers_count":75,"open_issues_count":1,"forks_count":14,"subscribers_count":5,"default_branch":"master","last_synced_at":"2025-03-28T15:51:50.646Z","etag":null,"topics":["bash","configuration-management","shell","ssh"],"latest_commit_sha":null,"homepage":"","language":"Shell","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/bltavares.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}},"created_at":"2014-02-22T00:29:48.000Z","updated_at":"2024-12-22T19:13:31.000Z","dependencies_parsed_at":"2022-09-10T23:30:53.311Z","dependency_job_id":null,"html_url":"https://github.com/bltavares/kickstart","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bltavares%2Fkickstart","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bltavares%2Fkickstart/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bltavares%2Fkickstart/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/bltavares%2Fkickstart/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/bltavares","download_url":"https://codeload.github.com/bltavares/kickstart/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249004708,"owners_count":21196929,"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":["bash","configuration-management","shell","ssh"],"created_at":"2024-10-16T14:16:35.097Z","updated_at":"2025-04-15T04:23:46.569Z","avatar_url":"https://github.com/bltavares.png","language":"Shell","funding_links":[],"categories":[],"sub_categories":[],"readme":"# kickstart\nBash only provisioning tool.\n\nThe idea is to use bash scripts to provision machines over ssh, with no client installation on the target.\nIt provides some abstractions and functions that help you structure and write more readable bash scripts.\n\nFor an example project, check [my homelab](https://github.com/bltavares/homelab), the [tty.space project](https://github.com/bltavares/tty.space) or\n[kickstart-baseline](https://github.com/bltavares/kickstart-baseline).\n\n### Goal\n\n* No installation on the target\n* Over ssh, or local\n* Portable (Mac, Linux, containers and so on)\n\n\n### Documentation\n\nKickstart provides offline documentation using the `kickstart doc` command as well as an online on http://bltavares.viewdocs.io/kickstart.\n\nAutocompletion is enabled for the offline documentation.\n\n### Installation\n\n#### Homebrew\n\n```bash\nbrew tap bltavares/tap\nbrew install --HEAD kickstart\n```\n\n#### [Basher](https://github.com/basherpm/basher)\n\n```bash\nbasher install bltavares/kickstart\n```\n\n### Arch Linux\n\n`kickstart-git` is available on [aur](https://aur.archlinux.org/packages/kickstart-git).\n\nYou can use the following command to install.\n\n```bash\nyaourt -S kickstart-git\n```\n\n#### Adding to the shell\n\nAdd it to the path.\n\nOne options is to download it, and export the bin folder into your PATH\n```bash\n# Adjust the paths to your preferred location\ninstallation_path=/opt/kickstart\nshell_configuration=$HOME/.bashrc\n\ngit clone https://github.com/bltavares/kickstart.git $installation_path\necho 'export PATH=$PATH:'$installation_path'/bin' \u003e\u003e $shell_configuration\n```\n\n#### Link under /usr/local/bin\n\nThe other is to link the `bin/kickstart` into a place that is already on your path.\n\nThis will allow `sudo` to see the `kickstart` command.\n```bash\n# Adjust the paths to your preferred location\ninstallation_path=/opt/kickstart\n\ngit clone https://github.com/bltavares/kickstart.git $installation_path\nsudo ln -s $installation_path/bin/kickstart /usr/local/bin/kickstart\n```\n\n### Autocompletion\n\nTo enable autocompletion run the following command:\n\n```bash\nshell_configuration=$HOME/.bashrc\necho 'eval \"$(kickstart autocomplete)\"' \u003e\u003e $shell_configuration\n```\n\nAdjust the shell configuration variable if you use a different shell.\n\n### Usage\n\n#### create\nCreates a sample project structure\n\n```bash\nkickstart create [folder name or current folder]\n```\n\n#### docker-create\nCreates a docker container with a running sshd to test recipes\n\n```bash\nkickstart docker-create [image-name]\n```\n\n#### docker-ssh\nAccess the created docker container over ssh. A simple utility that looks up for the port the docker is bound.\n\n```bash\nkickstart docker-ssh [image-name]\n```\n\n\n#### compile\nCompile the current workspace into the folder to be packaged on deploy\n\n```bash\nkickstart compile\n```\n\n#### deploy\nTakes an host target and deploy the compiled code on it.\n\n```bash\nkickstart deploy [--sudo] [--password PASSWORD] target [roles ...]\n```\n\n##### Examples\nDeploy a role on a host\n\n```bash\nkickstart deploy vagrant@localhost nodejs\n```\n\nDeploy two roles on a host with an alternative port\n\n```bash\nkickstart deploy \"-p 2222 vagrant@localhost\" nodejs redis\n```\n\nDeploy with sudo and send the password for sudo\n\n```bash\nkickstart deploy --sudo --password vagrant \"-p 2222 vagrant@localhost\" nodejs redis\n```\n\n#### local\nDeploy localy a recipe that is not over ssh. It basicaly compile and run the install script\n\n```bash\nkickstart local [--sudo] [roles ...]\n```\n\n#### infect\nInfect your shell with the kickstart utility functions\n\n```bash\neval \"$(kickstart infect)\"\n```\n\n#### bootstrap\nInstall kickstart on the target\n\n```bash\nkickstart bootstratp [target]\n```\n\n##### Example\nUsing default ssh configurations\n\n```bash\nkickstart bootstrap vagrant@vagrant\n```\n\nUsing alternate ssh port\n```bash\nkickstart bootstrap \"-p 2222 vagrant@vagrant\"\n```\n\n#### doc\nShow documentation for a kickstart function\n\n```bash\nkickstart doc [function name]\n```\n\n##### Example\nList all documented functions\n\n```bash\nkickstart doc\n```\n\nShow documentation for a function\n\n```bash\nkickstart doc kickstart.os\n```\n\n#### autocomplete\nEnable autocompletion on your terminal\n\n```bash\neval \"$(kickstart autocomplete)\"\n```\n\n### Debugging\nPrepend DEBUG=1 to the command and you will see massive ammount of commands on your screen\n\n```bash\nDEBUG=1 kickstart local nodejs\n```\n\n### Choosing the docker image to use\nYou can choose an specific image to use on the docker-* commands.\n\nOn order, it looks up for an image as an argument, on the `KICKSTART_DOCKER_IMAGE` env variable or defaults to moul/sshd.\nYou can use any image that is on the index, you probably want it to have an sshd running by default.\n\nDocker images tested:\n\n* [moul/sshd](https://index.docker.io/u/moul/sshd/)\n* [bltavares/centos-ssh](https://index.docker.io/u/bltavares/centos-ssh/)\n* [bltavares/arch-ssh](https://index.docker.io/u/bltavares/arch-ssh/)\n\n### Packaging\n\n#### .deb\nYou need to have make and fpm installed.\n\n```bash\nmake deb\n```\n\n### Thanks\nThis project was inspired on [sunzi](https://github.com/kenn/sunzi)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbltavares%2Fkickstart","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fbltavares%2Fkickstart","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fbltavares%2Fkickstart/lists"}