Open sufyanadam opened 4 years ago
Sorry for the delay in responding to this, I haven't been working on this project at all. I could probably add a flag to ignore failures. Will look at doing that as part of the next update
@sufyanadam Maybe you can ignore the error in your bash command:
cfcli add -t CNAME some-cname some-host || true
@lapwat that's what I'm doing for now.
@lapwat @danielpigott ignoring the error with || true
doesn't work for cases where you don't want the error ignored. For example creating the record failed due to invalid or empty DNS parameters. When building automations you want to know if there was something wrong with the input vs it already exists.
Is there an option we can pass so that
cfcli add -t CNAME some-cname some-host
does not fail if the record exists already? Maybe log a message that the record already exists. This would be helpful while building automations. Same for remove behaviour. Would this be possible?