The current regex is a bit too strict, for example "https://foreman-smartproxy-1.our.domain.com" should be correct.
However the current regex only allows for alpha numeric characters. the proposed change would only add dashes.
However making a RFC compliant regex is non trivial, below mentioned packages could offload that responsibility.
net/url .pase() could also be used
asaskevich/govalidator .isURL() is also another option
You were absolutely correct. And the terraform sdk already comes with a solution for this issue. I switched over the validation to their built-in http/https validation function in 59b76c0
Hi, thank you for all your work.
The current regex is a bit too strict, for example "https://foreman-smartproxy-1.our.domain.com" should be correct. However the current regex only allows for alpha numeric characters. the proposed change would only add dashes.
However making a RFC compliant regex is non trivial, below mentioned packages could offload that responsibility. net/url .pase() could also be used asaskevich/govalidator .isURL() is also another option