Giter Club home page Giter Club logo

Comments (8)

sostheim avatar sostheim commented on August 22, 2024

Change taints
The method by which taints were added to nodepools was a hack to work around a deficiency in kraken-lib at the time. That problem has since been fixed. Change nodepool definitions with taints per the following:

Original:

        - name: forayNodes
          count: 5
          kubeConfig: *colonybeadKube
          containerConfig: *defaultDocker
          osConfig: *defaultCoreOs
          nodeConfig: 
            << : *defaultAwsClusterNode
            taints:
              - key: customer
                value: foray
                effect: NoSchedule
          keyPair: *colonybeadKeyPair

New:

       - name: forayNodes
          count: 5
          kubeConfig: *colonybeadKube
          containerConfig: *defaultDocker
          osConfig: *defaultCoreOs
          nodeConfig: *defaultAwsClusterNode
          taints:
            - key: customer
              value: foray
              effect: NoSchedule
          keyPair: *colonybeadKeyPair

from krak8s.

sostheim avatar sostheim commented on August 22, 2024

/CC @joejulian @davidewatson

from krak8s.

davidewatson avatar davidewatson commented on August 22, 2024

/lgtm

from krak8s.

davidewatson avatar davidewatson commented on August 22, 2024

Hold on. My comment above was based on the schema change @joejulian made in kraken-lib/1026. However, a quick glance at this code:

---
- set_fact:
    taints: "{{ new_taints }}"
    taints_exist: "{{ new_taints | length > 0 | bool }}"
  vars:
    nodePoolTaintQuery: "{{ node | json_query('schedulingConfig.taints[*]') }}"
    nodePoolTaints: "{{ (nodePoolTaintQuery == '') | ternary([],nodePoolTaintQuery) }}"
    nodeTypeTaintQuery: "{{ node | json_query('nodeConfig.taints[*]') }}"
    nodeTypeTaints: "{{ (nodeTypeTaintQuery == '') | ternary([],nodeTypeTaintQuery) }}"
    new_taints: "{{ nodePoolTaints + nodeTypeTaints }}"

makes me wonder where the nodePool level taints are picked up in ansible.

I haven't looked far, so maybe everything is fine. We obviously need to test this though.

from krak8s.

sostheim avatar sostheim commented on August 22, 2024

@davidewatson - holding.

from krak8s.

davidewatson avatar davidewatson commented on August 22, 2024

Yeah, this won't work. Using the config file here:

        - name: forayNodes
          count: 5
          kubeConfig: *colonybeadKube
          containerConfig: *defaultDocker
          osConfig: *defaultCoreOs
          nodeConfig: *defaultAwsClusterNode
          keyPair: *colonybeadKeyPair
          taints:
            - key: customer
              value: foray
              effect: NoSchedule

I end up with no taints:

Name:			ip-10-0-104-151.ec2.internal
Role:			
Labels:			beta.kubernetes.io/arch=amd64
			beta.kubernetes.io/instance-type=m4.2xlarge
			beta.kubernetes.io/os=linux
			failure-domain.beta.kubernetes.io/region=us-east-1
			failure-domain.beta.kubernetes.io/zone=us-east-1b
			kubernetes.io/hostname=ip-10-0-104-151.ec2.internal
			nodepool=forayNodes
Annotations:		node.alpha.kubernetes.io/ttl=0
			volumes.kubernetes.io/controller-managed-attach-detach=true
Taints:			<none>
CreationTimestamp:	Thu, 21 Dec 2017 07:52:57 -0800

@joejulian: ^^

from krak8s.

joejulian avatar joejulian commented on August 22, 2024

Yep, my failure to read.

Looks like it should be

        - name: forayNodes
          count: 5
          kubeConfig: *colonybeadKube
          containerConfig: *defaultDocker
          osConfig: *defaultCoreOs
          nodeConfig: *defaultAwsClusterNode
          keyPair: *colonybeadKeyPair
          schedulingConfig:
            taints:
              - key: customer
                value: foray
                effect: NoSchedule

This passes the schema check but I don't know if it produces the taints.

from krak8s.

sostheim avatar sostheim commented on August 22, 2024

#17 merged.

from krak8s.

Related Issues (12)

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.