identifiers

package
v2.0.0-rc.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 17, 2024 License: Apache-2.0 Imports: 3 Imported by: 0

Documentation

Overview

Package identifiers implements functions for docker compatible identifier validation.

Index

Constants

View Source
const AllowedIdentfierChars = `[a-zA-Z0-9][a-zA-Z0-9_.-]`

Variables

View Source
var AllowedIdentifierPattern = regexp.MustCompile(`^` + AllowedIdentfierChars + `+$`)

Functions

func ValidateDockerCompat

func ValidateDockerCompat(s string) error

ValidateDockerCompat implements docker compatible identifier validation. The containerd implementation allows single character identifiers, while the Docker compatible implementation requires at least 2 characters for identifiers. The containerd implementation enforces a maximum length constraint of 76 characters, while the Docker compatible implementation omits the length check entirely.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL