Artifacts definition for a CodeBuild Project.
Implements
Namespace: Amazon.CDK.AWS.CodeBuild
Assembly: Amazon.CDK.Lib.dll
Syntax (csharp)
public abstract class Artifacts : DeputyBase, IArtifacts
Syntax (vb)
Public MustInherit Class Artifacts Inherits DeputyBase Implements IArtifacts
Examples
Bucket bucket;
var project = new Project(this, "MyProject", new ProjectProps {
BuildSpec = BuildSpec.FromObject(new Dictionary<string, object> {
{ "version", "0.2" }
}),
Artifacts = Artifacts.S3(new S3ArtifactsProps {
Bucket = bucket,
IncludeBuildId = false,
PackageZip = true,
Path = "another/path",
Identifier = "AddArtifact1"
})
});
Synopsis
Constructors
Properties
| Identifier | The artifact identifier. |
| Type | The CodeBuild type of this artifact. |
Methods
Constructors
Artifacts(IArtifactsProps)
Artifacts definition for a CodeBuild Project.
protected Artifacts(IArtifactsProps props)
Parameters
- props IArtifactsProps
Examples
Bucket bucket;
var project = new Project(this, "MyProject", new ProjectProps {
BuildSpec = BuildSpec.FromObject(new Dictionary<string, object> {
{ "version", "0.2" }
}),
Artifacts = Artifacts.S3(new S3ArtifactsProps {
Bucket = bucket,
IncludeBuildId = false,
PackageZip = true,
Path = "another/path",
Identifier = "AddArtifact1"
})
});
Properties
Identifier
Type
Methods
Bind(Construct, IProject)
Callback when an Artifacts class is used in a CodeBuild Project.
public virtual IArtifactsConfig Bind(Construct scope, IProject project)
Parameters
- scope Construct
- project IProject
Returns
S3(IS3ArtifactsProps)
Artifacts definition for a CodeBuild Project.
public static IArtifacts S3(IS3ArtifactsProps props)
Parameters
- props IS3ArtifactsProps
Returns
Examples
Bucket bucket;
var project = new Project(this, "MyProject", new ProjectProps {
BuildSpec = BuildSpec.FromObject(new Dictionary<string, object> {
{ "version", "0.2" }
}),
Artifacts = Artifacts.S3(new S3ArtifactsProps {
Bucket = bucket,
IncludeBuildId = false,
PackageZip = true,
Path = "another/path",
Identifier = "AddArtifact1"
})
});