Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix - Incomplete regular expression for hostnames #1993

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions pkg/constants/constants.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const (
// RootDir is the path to the root directory
RootDir = "/"

//KanikoDir is the path to the Kaniko directory
// KanikoDir is the path to the Kaniko directory
KanikoDir = "/kaniko"

IgnoreListPath = "/proc/self/mountinfo"
Expand Down Expand Up @@ -76,8 +76,9 @@ const (
var ScratchEnvVars = []string{"PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin"}

// AzureBlobStorageHostRegEx is ReqEX for Valid azure blob storage host suffix in url for AzureCloud, AzureChinaCloud, AzureGermanCloud and AzureUSGovernment
var AzureBlobStorageHostRegEx = []string{"https://(.+?).blob.core.windows.net/(.+)",
"https://(.+?).blob.core.chinacloudapi.cn/(.+)",
"https://(.+?).blob.core.cloudapi.de/(.+)",
"https://(.+?).blob.core.usgovcloudapi.net/(.+)",
var AzureBlobStorageHostRegEx = []string{
"https://(.+?)\\.blob\\.core\\.windows\\.net/(.+)",
"https://(.+?)\\.blob\\.core\\.chinacloudapi\\.cn/(.+)",
"https://(.+?)\\.blob\\.core\\.cloudapi\\.de/(.+)",
"https://(.+?)\\.blob\\.core\\.usgovcloudapi\\.net/(.+)",
}