Giter VIP home page Giter VIP logo

ansible-role-kubernetes-headphones's Introduction

Ansible Role: Headphones for Kubernetes

Ansible role to install Headphones on Kubernetes.

Role Variables

# Namespace
kubernetes_headphones_namespace: "default"
# App name (used as selector)
kubernetes_headphones_app: "headphones"
# Deployment name
kubernetes_headphones_deployment: "headphones-deployment"
# Service name
kubernetes_headphones_service: "headphones"

# Number of replicas
kubernetes_headphones_replicas: 1
kubernetes_headphones_revision_history: 1

# Node selector
kubernetes_headphones_node_selector: {}

# Add custom labels in the deployment metadata section
kubernetes_headphones_deployment_labels: {}
# Add custom annotations in the deployment metadata section
kubernetes_headphones_deployment_annotations: {}

kubernetes_headphones_resources:
  limits:
    memory: "756Mi"
  requests:
    memory: "256Mi"

# Setup ingress for headphones
kubernetes_headphones_setup_ingress: false
kubernetes_headphones_ingress:
  name: "headphones-ingress"
  host: "headphones.example.com"
  annotations:
  tls:

### Volumes ###

# For each volume, `definition` and `subPath` can be used. Their content is
# exactly what would be in a Kkubernetes pod manifest.

# Downloads volumes. Mounted in /downloads/ (see examples for more details)
kubernetes_headphones_downloads_volumes: {}
# Music volumes. Mounted in /music/ (see examples for more details)
kubernetes_headphones_music_volumes: {}
# Watch directories. Useful when blackhole is used. Mounted in /watchdirs/ (see
# examples for more details)
kubernetes_headphones_watchdirs_volumes: {}

# Enby config volume. Contains the database, arts cache and config.
kubernetes_headphones_config_volume:
  definition:

Dependencies

Kubectl needs to be installed on the host targeted by the role.

Example Playbook

- hosts: kube-master
  run_once: true
  vars:
    kubernetes_headphones_downloads_volumes:
      # This volume will be mounted as /downloads/completed
      completed:
        definition:
          glusterfs:
            endpoints: gluster-example-cluster
            path: volume-torrents
            readOnly: false
        subPath: "completed"

    kubernetes_headphones_music_volumes:
      # This volume will be mounted as /music/global
      global:
        definition:
          glusterfs:
            endpoints: gluster-example-cluster
            path: volume-music
            readOnly: false

    # Directories watched by our torrents client
    kubernetes_headphones_watchdirs_volumes:
      # This volume will be mounted as /watchdirs/providers
      providers:
        definition:
          glusterfs:
            endpoints: gluster-example-cluster
            path: volume-watchdirs
            readOnly: false
        subPath: "example/providers"

    kubernetes_headphones_config_volume:
      definition:
        glusterfs:
          endpoints: gluster-example-cluster
          path: volume-headphones
          readOnly: false
        subPath: "config"

    kubernetes_headphones_setup_ingress: true
    kubernetes_headphones_ingress:
      name: "headphones-ingress"
      host: "headphones.example.com"
      annotations:
        kubernetes.io/tls-acme: "true"
      tls:
        - secretName: "headphones-ingress-tls"
          hosts:
            - "headphones.example.com"
  roles:
    - role: Anthony25.kubernetes-headphones

Use run_once to run the role on only one available master in the cluster.

If the headphones web interface is not reachable, please check that it is listening on 0.0.0.0, and not only localhost. Also check that the public http port is setup as 8181.

License

Tool under the BSD license. Do not hesitate to report bugs, ask me some questions or do some pull request if you want to!

ansible-role-kubernetes-headphones's People

Contributors

aruhier avatar

Watchers

 avatar  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.