Skip to content

Commit 653b8b6

Browse files
authored
Merge pull request #107 from juchong/main
Fixed invalid escape sequence errors
2 parents 41ce805 + b904fcd commit 653b8b6

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

install/usr/sbin/cloudflare-companion

+2-2
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ def check_container_t2(c):
286286
def label_host():
287287
for prop in c.attrs.get(u'Config').get(u'Labels'):
288288
value = c.attrs.get(u'Config').get(u'Labels').get(prop)
289-
if re.match('traefik.*?\.rule', prop):
289+
if re.match(r'traefik.*?\.rule', prop):
290290
if 'Host' in value:
291291
logger.debug("Container ID: %s rule value: %s", cont_id, value)
292292
extracted_domains = re.findall(r'\`([a-zA-Z0-9\.\-]+)\`', value)
@@ -319,7 +319,7 @@ def check_service_t2(s):
319319
def label_host():
320320
for prop in s.attrs.get(u'Spec').get(u'Labels'):
321321
value = s.attrs.get(u'Spec').get(u'Labels').get(prop)
322-
if re.match('traefik.*?\.rule', prop):
322+
if re.match(r'traefik.*?\.rule', prop):
323323
if 'Host' in value:
324324
logger.debug("Service ID: %s rule value: %s", cont_id, value)
325325
extracted_domains = re.findall(r'\`([a-zA-Z0-9\.\-]+)\`', value)

0 commit comments

Comments
 (0)