Git Product home page Git Product logo

ansible-kubestack's Introduction

KubeStack

This ansible role can install basic components for kubernetes cluster:

  • MetalLB
  • CertManager
  • Nginx Ingress Controller
  • Longhorn CSI
  • Loki
  • Rancher Manager
  • Vault

Requirements

This role requires the following:

Role Variables

stack_metallb:
  pools: 
  - 127.0.0.1-127.0.0.1
  enabled: true
  namespace: metallb-system
stack_cert_manager:
  version: v1.13.2
  namespace: cert-manager
  enabled: true
stack_nginx_controllers:
  - version: 4.8.3
    ingress_class_by_name: true
    ssl_passthrough: true
    service_type: LoadBalancer
    loadBalancerIP: 127.0.0.1
    ingressClass: nginx
    namespace: ingress-nginx
stack_rancher: 
  hostname: rancher.example.com
  bootstrapPassword: admin
  replicas: 1
  namespace: cattle-system
  enabled: true
  ingressClass: nginx
stack_longhorn:
  enabled: true
  replicas: 2
  ui: Rancher-Proxy
  namespace: longhorn-system
stack_loki:
  enabled: true
  namespace: loki
  persistence_enabled: true
  persistence_size: 10Gi
stack_argocd:
  enabled: true
  namespace: argocd
  hosts:
  - argocd.example.com
  vault_addr: http://vault.example.com:8200
  vault_token: hvs.token
  ingressClass: nginx
  refresh_interval: 180s
stack_vault:
  enabled: true
  namespace: vault
  externalVaultAddr: http://vault.example.com:8200
  server:
    enabled: true
    ingress:
      enabled: true
      ingressClassName: nginx
      host: test.example.com
  injector:
    enabled: false
use_manifests: true
manifests_path: /var/lib/rancher/rke2/server/manifests
kubeconfig: ~/.kube/config

Dependencies

This role depends only on:

Example Playbook

Example playbook to install everything except vault (its already integrated into argocd):

    - hosts: localhost
      vars:
        manifests_path: /tmp
        use_manifests: false
        kubeconfig: ~/.kube/config
        stack_metallb:
          pools: 
          - 192.168.0.200-192.168.0.250
          enabled: true
          namespace: metallb-system
        stack_cert_manager:
          version: v1.13.2
          namespace: cert-manager
          enabled: true
        stack_nginx_controllers:
          - version: 4.8.3
            ingress_class_by_name: true
            ssl_passthrough: true
            service_type: LoadBalancer
            loadBalancerIP: 192.168.0.200
            ingressClass: nginx
            namespace: ingress-nginx
        stack_rancher: 
          hostname: rancher.example.com
          bootstrapPassword: admin
          replicas: 1
          namespace: cattle-system
          enabled: true
          ingressClass: nginx
        stack_argocd:
          enabled: true
          namespace: argocd
          hosts:
          - argocd.example.com
          vault_addr: http://vault.example.com:8200
          vault_token: hvs.token
          ingressClass: nginx
          refresh_interval: 60s
        stack_vault:
          enabled: false
      roles:
        - role: kube-stack

License

MIT License

Copyright (c) 2023 Tarek Srour

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

ansible-kubestack's People

Watchers

Tarek Srour avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.