You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pulsar.apache.org by GitBox <gi...@apache.org> on 2021/10/22 08:44:40 UTC

[GitHub] [pulsar-helm-chart] matejhasul opened a new pull request #166: Workaround kustomize bug in pulsar cluster init

matejhasul opened a new pull request #166:
URL: https://github.com/apache/pulsar-helm-chart/pull/166


   ### Motivation
   
   Due to bug in kustomize https://github.com/kubernetes-sigs/kustomize/issues/4201 we cannot deploy pulsar helm chart via fluxcd which uses kustomize as post-renderer (as desribed in https://github.com/fluxcd/flux2/issues/1968). Pulsar cluster initialization fails, because jobs responsible for initialization is missing some arguments due extra newline:
   ```
   $ kubectl -n pulsar get job pulsar-pulsar-init -o yaml | grep initialize-cluster-metadata -B3 -A3
         - args:
           - |2
   
             bin/pulsar initialize-cluster-metadata \
   
               --cluster pulsar \
               --zookeeper pulsar-zookeeper:2181 \
   ```
   There are also other places where this bug is hit, but extra generated newline is not significant and does no break anything.
   
   ### Modifications
   
   Replace folding block with multiline string to workaround https://github.com/kubernetes-sigs/kustomize/issues/4201
   
   
   
   ### Verifying this change
   
   - [ ] Make sure that the change passes the CI checks.
   
   1. Prepare kustomization file:
   ```
   cat <<EOT >./kustomization.yaml
   resources:
   - pulsar-init.yaml
   EOT
   ```
   2. Run helm to generate k8s manifests for pulsar init jobs:
   ```
   $ helm template . -s templates/pulsar-cluster-initialize.yaml --set initialize=true > pulsar-init.yaml
   ```
   3. Run kustomize:
   ```
   kustomize build . > pulsar-init-kustomized.yaml
   ```
   4. Check that there is no extra newline in arguments of pulsar cluster initialization job:
   ```
   $ grep initialize-cluster-metadata -B3 -A3 pulsar-init-kustomized.yaml
   ```


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar-helm-chart] matejhasul commented on pull request #166: Workaround kustomize bug in pulsar cluster init

Posted by GitBox <gi...@apache.org>.
matejhasul commented on pull request #166:
URL: https://github.com/apache/pulsar-helm-chart/pull/166#issuecomment-961882811


   Is anyone willing to review this?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar-helm-chart] michaeljmarshall merged pull request #166: Workaround kustomize bug in pulsar cluster init

Posted by GitBox <gi...@apache.org>.
michaeljmarshall merged pull request #166:
URL: https://github.com/apache/pulsar-helm-chart/pull/166


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar-helm-chart] matejhasul commented on pull request #166: Workaround kustomize bug in pulsar cluster init

Posted by GitBox <gi...@apache.org>.
matejhasul commented on pull request #166:
URL: https://github.com/apache/pulsar-helm-chart/pull/166#issuecomment-961882811


   Is anyone willing to review this?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [pulsar-helm-chart] matejhasul commented on pull request #166: Workaround kustomize bug in pulsar cluster init

Posted by GitBox <gi...@apache.org>.
matejhasul commented on pull request #166:
URL: https://github.com/apache/pulsar-helm-chart/pull/166#issuecomment-961882811


   Is anyone willing to review this?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: dev-unsubscribe@pulsar.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org