crane
Crane is a tool for managing container images
Installation
dagger install github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c
Entrypoint
Return Type
Crane !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
image | String ! | "cgr.dev/chainguard/crane:latest" | Crane image |
registryUsername | String | null | No description provided |
registryPassword | Secret | null | No description provided |
user | String ! | "nonroot" | Cosign image user |
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string
func (m *myModule) example(image string, user string) *Crane {
return dag.
Crane(image, user)
}
@function
def example(image: str, user: str) -> dag.Crane:
return (
dag.crane(image, user)
)
@func()
example(image: string, user: string): Crane {
return dag
.crane(image, user)
}
Types
Crane 🔗
Crane module
image() 🔗
Crane image
Return Type
String !
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string image
func (m *myModule) example(ctx context.Context, image string, user string) string {
return dag.
Crane(image, user).
Image(ctx)
}
@function
async def example(image: str, user: str) -> str:
return await (
dag.crane(image, user)
.image()
)
@func()
async example(image: string, user: string): Promise<string> {
return dag
.crane(image, user)
.image()
}
registryUsername() 🔗
Return Type
String
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string registry-username
func (m *myModule) example(ctx context.Context, image string, user string) string {
return dag.
Crane(image, user).
RegistryUsername(ctx)
}
@function
async def example(image: str, user: str) -> str:
return await (
dag.crane(image, user)
.registry_username()
)
@func()
async example(image: string, user: string): Promise<string> {
return dag
.crane(image, user)
.registryUsername()
}
registryPassword() 🔗
Return Type
Secret
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string registry-password
func (m *myModule) example(image string, user string) *Secret {
return dag.
Crane(image, user).
RegistryPassword()
}
@function
def example(image: str, user: str) -> dagger.Secret:
return (
dag.crane(image, user)
.registry_password()
)
@func()
example(image: string, user: string): Secret {
return dag
.crane(image, user)
.registryPassword()
}
user() 🔗
Cosign image user
Return Type
String !
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string user
func (m *myModule) example(ctx context.Context, image string, user string) string {
return dag.
Crane(image, user).
User(ctx)
}
@function
async def example(image: str, user: str) -> str:
return await (
dag.crane(image, user)
.user()
)
@func()
async example(image: string, user: string): Promise<string> {
return dag
.crane(image, user)
.user()
}
manifest() 🔗
Get the manifest of an image
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
image | String ! | - | Image |
platform | String | null | No description provided |
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string manifest --image string
func (m *myModule) example(ctx context.Context, image string, user string, image1 string) string {
return dag.
Crane(image, user).
Manifest(ctx, image1)
}
@function
async def example(image: str, user: str, image1: str) -> str:
return await (
dag.crane(image, user)
.manifest(image1)
)
@func()
async example(image: string, user: string, image1: string): Promise<string> {
return dag
.crane(image, user)
.manifest(image1)
}
digest() 🔗
Tag remote image without downloading it.
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
image | String ! | - | Image |
platform | String | null | No description provided |
fullRef | Boolean | false | No description provided |
tarball | String | null | No description provided |
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string digest --image string
func (m *myModule) example(ctx context.Context, image string, user string, image1 string) string {
return dag.
Crane(image, user).
Digest(ctx, image1)
}
@function
async def example(image: str, user: str, image1: str) -> str:
return await (
dag.crane(image, user)
.digest(image1)
)
@func()
async example(image: string, user: string, image1: string): Promise<string> {
return dag
.crane(image, user)
.digest(image1)
}
cp() 🔗
Tag remote image without downloading it.
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
source | String ! | - | Source image |
target | String ! | - | Target image |
platform | String | null | No description provided |
jobs | Integer | null | No description provided |
allTags | Boolean | false | No description provided |
noClobber | Boolean | false | No description provided |
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string cp --source string --target string
func (m *myModule) example(ctx context.Context, image string, user string, source string, target string) string {
return dag.
Crane(image, user).
Cp(ctx, source, target)
}
@function
async def example(image: str, user: str, source: str, target: str) -> str:
return await (
dag.crane(image, user)
.cp(source, target)
)
@func()
async example(image: string, user: string, source: string, target: string): Promise<string> {
return dag
.crane(image, user)
.cp(source, target)
}
tag() 🔗
Tag remote image without downloading it.
Return Type
String !
Arguments
Name | Type | Default Value | Description |
---|---|---|---|
image | String ! | - | Image |
tag | String ! | - | New tag |
platform | String | null | No description provided |
Example
dagger -m github.com/opopops/daggerverse/crane@79329a209909e4cea2c0985542b8e7ecba16838c call \
--image string --user string tag --image string --tag string
func (m *myModule) example(ctx context.Context, image string, user string, image1 string, tag string) string {
return dag.
Crane(image, user).
Tag(ctx, image1, tag)
}
@function
async def example(image: str, user: str, image1: str, tag: str) -> str:
return await (
dag.crane(image, user)
.tag(image1, tag)
)
@func()
async example(image: string, user: string, image1: string, tag: string): Promise<string> {
return dag
.crane(image, user)
.tag(image1, tag)
}