tinkerbell / playground

Example deployments of the Tinkerbell Stack for use as playground environments
Apache License 2.0
132 stars 87 forks source link

Add sleep to reduce logging output #193

Closed ttwd80 closed 3 months ago

ttwd80 commented 3 months ago

Description

The command kubectl get nodes -o 'jsonpath={.items[*].spec.podCIDR}' is executed in a loop. When I run vagrant up the my screen is filled with:

    stack: ++ kubectl get nodes -o 'jsonpath={.items[*].spec.podCIDR}'
    stack: ++ tr ' ' ,
    stack: + trusted_proxies=
    stack: + '[' '' '!=' '' ']'
    stack: ++ kubectl get nodes -o 'jsonpath={.items[*].spec.podCIDR}'
    stack: ++ tr ' ' ,
    stack: + trusted_proxies=
    stack: + '[' '' '!=' '' ']'
    stack: ++ kubectl get nodes -o 'jsonpath={.items[*].spec.podCIDR}'
    stack: ++ tr ' ' ,
    stack: + trusted_proxies=
    stack: + '[' '' '!=' '' ']'

Why is this needed

To reduce the verbosity.

Fixes: #

How Has This Been Tested?

Tested on my on machine. It worked before the change. It worked after the change with less output.

    stack: + local loadbalancer_ip=192.168.56.5
    stack: + trusted_proxies=
    stack: + '[' '' '!=' '' ']'
    stack: ++ kubectl get nodes -o 'jsonpath={.items[*].spec.podCIDR}'
    stack: ++ tr ' ' ,
    stack: + trusted_proxies=
    stack: + sleep 5
    stack: + '[' '' '!=' '' ']'
    stack: ++ kubectl get nodes -o 'jsonpath={.items[*].spec.podCIDR}'
    stack: ++ tr ' ' ,
    stack: + trusted_proxies=
    stack: + sleep 5
    stack: + '[' '' '!=' '' ']'
    stack: ++ tr ' ' ,
    stack: ++ kubectl get nodes -o 'jsonpath={.items[*].spec.podCIDR}'
    stack: + trusted_proxies=10.42.0.0/24
    stack: + sleep 5
    stack: + '[' 10.42.0.0/24 '!=' '' ']'
    stack: + helm install tink-stack oci://ghcr.io/tinkerbell/charts/stack --version 0.4.5 --create-namespace --namespace tink-system --wait --set 'smee.trustedProxies={10.42.0.0/24}' --set 'hegel.trustedProxies={10.42.0.0/24}' --set stack.kubev

How are existing users impacted? What migration steps/scripts do we need?

None

Checklist:

I have: