ZackingIt edited a comment on issue #10605:
URL: https://github.com/apache/airflow/issues/10605#issuecomment-957069715


   > > airflowLocalSettings: |
   > > from airflow.providers.cncf.kubernetes.utils.xcom_sidecar import 
PodDefaults
   > > PodDefaults.SIDECAR_CONTAINER.image = private.registry.com/alpine
   > 
   > @fritzb
   > 
   > I tried something like this in the past and it didnt work. However this 
worked for me in 2.2.0, so thank you!
   
   I was able to get my xcom to use a non-DockerHub repo also by creating a 
`airflow_local_settings.py` file in the root/config folder, due to this yaml:
   
https://github.com/apache/airflow/blob/73044af1c6908d1b075bd0127bc56c1db82b564b/chart/templates/_helpers.yaml#L416.
   
   I then simply overwrote with the code:
   ```
   from airflow.providers.cncf.kubernetes.utils.xcom_sidecar import PodDefaults
   PodDefaults.SIDECAR_CONTAINER.image = 
"docker.very.private.repo.net/alpine:3.10"
   ```
   You can verify the custom `airflow_local_settings.py` file is loaded because 
any code written in that file will be executed by teach task instance, i.e., 
those are the logs to check.  That's really the only annoying/hard part, is 
just knowing whether your instance is actually executing/including the 
local_settings file.
   
   Also note that this works even as early as at least 2.1.0 for those of you 
who are having issues with 2.2.0 :)


-- 
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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to