fix: change logs in omi config
This commit is contained in:
parent
1281f28f6d
commit
3d8b0e5228
|
@ -136,7 +136,7 @@ func (c *OMIConfig) prepareRegions(accessConfig *AccessConfig) (errs []error) {
|
||||||
if (accessConfig != nil) && (region == accessConfig.RawRegion) {
|
if (accessConfig != nil) && (region == accessConfig.RawRegion) {
|
||||||
// make sure we don't try to copy to the region we originally
|
// make sure we don't try to copy to the region we originally
|
||||||
// create the OMI in.
|
// create the OMI in.
|
||||||
log.Printf("Cannot copy OMI to AWS session region '%s', deleting it from `omi_regions`.", region)
|
log.Printf("Cannot copy OMI to OUTSCALE session region '%s', deleting it from `omi_regions`.", region)
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
regions = append(regions, region)
|
regions = append(regions, region)
|
||||||
|
@ -147,7 +147,6 @@ func (c *OMIConfig) prepareRegions(accessConfig *AccessConfig) (errs []error) {
|
||||||
return errs
|
return errs
|
||||||
}
|
}
|
||||||
|
|
||||||
// See https://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_CopyImage.html
|
|
||||||
func validateKmsKey(kmsKey string) (valid bool) {
|
func validateKmsKey(kmsKey string) (valid bool) {
|
||||||
kmsKeyIdPattern := `[a-f0-9-]+$`
|
kmsKeyIdPattern := `[a-f0-9-]+$`
|
||||||
aliasPattern := `alias/[a-zA-Z0-9:/_-]+$`
|
aliasPattern := `alias/[a-zA-Z0-9:/_-]+$`
|
||||||
|
|
Loading…
Reference in New Issue