Skip to content

DockerIgnoreStrategy

Ignores file paths based on the .dockerignore specification.

Initializers

import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore"
alicloudroscdkcore.NewDockerIgnoreStrategy(absoluteRootPath *string, patterns *[]*string) DockerIgnoreStrategy
Name Type Description
absoluteRootPath *string No description.
patterns []string No description.

absoluteRootPathRequired

  • Type: *string

patternsRequired

  • Type: []string

Methods

Name Description
Add Adds another pattern.
Ignores Determines whether a given file path should be ignored or not.

Add

func Add(pattern *string)

Adds another pattern.

patternRequired

  • Type: *string

Ignores

func Ignores(absoluteFilePath *string) *bool

Determines whether a given file path should be ignored or not.

absoluteFilePathRequired

  • Type: *string

absolute file path to be assessed against the pattern.


Static Functions

Name Description
Docker Ignores file paths based on the .dockerignore specification.
FromCopyOptions Creates an IgnoreStrategy based on the ignoreMode and exclude in a CopyOptions.
Git Ignores file paths based on the .gitignore specification.
Glob Ignores file paths based on simple glob patterns.

Docker

import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore"
alicloudroscdkcore.DockerIgnoreStrategy_Docker(absoluteRootPath *string, patterns *[]*string) DockerIgnoreStrategy

Ignores file paths based on the .dockerignore specification.

absoluteRootPathRequired

  • Type: *string

the absolute path to the root directory of the paths to be considered.


patternsRequired

  • Type: []string

FromCopyOptions

import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore"
alicloudroscdkcore.DockerIgnoreStrategy_FromCopyOptions(options CopyOptions, absoluteRootPath *string) IgnoreStrategy

Creates an IgnoreStrategy based on the ignoreMode and exclude in a CopyOptions.

optionsRequired

the CopyOptions to create the IgnoreStrategy from.


absoluteRootPathRequired

  • Type: *string

the absolute path to the root directory of the paths to be considered.


Git

import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore"
alicloudroscdkcore.DockerIgnoreStrategy_Git(absoluteRootPath *string, patterns *[]*string) GitIgnoreStrategy

Ignores file paths based on the .gitignore specification.

absoluteRootPathRequired

  • Type: *string

the absolute path to the root directory of the paths to be considered.


patternsRequired

  • Type: []string

Glob

import "github.com/alibabacloud-go/ros-cdk/alicloudroscdkcore"
alicloudroscdkcore.DockerIgnoreStrategy_Glob(absoluteRootPath *string, patterns *[]*string) GlobIgnoreStrategy

Ignores file paths based on simple glob patterns.

absoluteRootPathRequired

  • Type: *string

the absolute path to the root directory of the paths to be considered.


patternsRequired

  • Type: []string