Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/moody-san/ansible-k8s-deployment
Ansible playbooks to automate kubernetes cluster deployment
https://github.com/moody-san/ansible-k8s-deployment
ansible ansible-playbook ansible-role automation kubernetes kubernetes-deployment
Last synced: 3 days ago
JSON representation
Ansible playbooks to automate kubernetes cluster deployment
- Host: GitHub
- URL: https://github.com/moody-san/ansible-k8s-deployment
- Owner: Moody-san
- Created: 2023-08-02T13:40:59.000Z (over 1 year ago)
- Default Branch: master
- Last Pushed: 2024-02-19T20:16:14.000Z (9 months ago)
- Last Synced: 2024-04-14T13:58:35.613Z (7 months ago)
- Topics: ansible, ansible-playbook, ansible-role, automation, kubernetes, kubernetes-deployment
- Language: Smarty
- Homepage:
- Size: 26.4 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Ansible Kubernetes Deployment
This repository contains Ansible playbooks and scripts for deploying a Kubernetes cluster with Kubeadm.
## Prerequisites- **Infra provisioned through IAC**: Deployed infrastructure using [terraform multi cloud iac](https://github.com/Moody-san/terraform-multicloud-infra) (as it contains a module to automatically update inventory for ansible scripts given that ansible repo and terraform repo are in the same directories).
- **Ansible Controller Scripts**: Run the setupiptables.yml and acceptfingerprint.yml from ansible_controller_setup repository . Link in Additional Resources .
- **Software Requirements**: Ensure Ansible cli is installed.## Installation
Clone the repository to your local machine to get started with the Kubernetes deployment:
```bash
git clone https://github.com/Moody-san/ansible-k8s-deployment.git
cd ansible-k8s-deployment/playbooks
```
## Usage
```bash
ansible-playbook initmaster.yml -i ../inventory/oracleinventory
ansible-playbook addworkernodes.yml -i ../inventory/oracleinventory
ansible-playbook addcontrolnodes.yml -i ../inventory/oracleinventory
ansible-playbook addistiomesh.yml -i ../inventory/oracleinventory
```
## Configurationyou can use the -l limit tag to add specific nodes only for example
```bash
ansible-playbook addworkernodes.yml -i ../inventory/oracleinventory -l oraclemaster,oracleworker
```## Additional Resources
- **MariaDB Cluster Setup**: For setting up a MariaDB cluster with Kubernetes-based failover, visit [ansible-galeracluster-deployment](https://github.com/Moody-san/ansible-galeracluster-deployment).
- **CI/CD and Automation**: For CI/CD and other automation scripts, refer to [ansible-controller-setup](https://github.com/Moody-san/ansible-controller-setup).## Notes
- You will be prompted for your private load balancer ip when initializing kubernetes cluster . The one provisioned through the terraform .
- When using limit with for example with addworkernodes oraclemaster is required as we use oracle master to generate the join string .## Demo
https://www.youtube.com/watch?v=7lCZTS3z6kk