dstandish commented on code in PR #27737:
URL: https://github.com/apache/airflow/pull/27737#discussion_r1027031707


##########
airflow/kubernetes/kubernetes_helper_functions.py:
##########
@@ -26,22 +26,7 @@
 log = logging.getLogger(__name__)
 
 
-def _strip_unsafe_kubernetes_special_chars(string: str) -> str:
-    """
-    Kubernetes only supports lowercase alphanumeric characters, "-" and "." in
-    the pod name.
-    However, there are special rules about how "-" and "." can be used so let's

Review Comment:
   A pod name must start and end with an alphanumeric character, i.e. 
`[a-z0-9]`.   So you can't have a leading or trailing `-` or `.`.
   
   If you try to create a pod that violates this, you'll get this error:
   ```
   a lowercase RFC 1123 subdomain must consist of lower case alphanumeric 
characters, '-' or '.', and must start and end with an alphanumeric character 
(e.g. 'example.com', regex used for validation is 
'[a-z0-9]([-a-z0-9]*[a-z0-9])?(\.[a-z0-9]([-a-z0-9]*[a-z0-9])?)*')
   ```



-- 
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