bucketuploader
No long description provided.
Installation
dagger install github.com/papercomputeco/daggerverse/bucketupload@ea0f099e3460fb50812c647745d5ead21c23a150Entrypoint
Return Type
Bucketuploader !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| endpoint | Secret ! | - | Bucket endpoint URL |
| bucket | Secret ! | - | Bucket name |
| accessKeyId | Secret ! | - | Bucket access key ID |
| secretAccessKey | Secret ! | - | Bucket secret access key |
Example
dagger -m github.com/papercomputeco/daggerverse/bucketupload@ea0f099e3460fb50812c647745d5ead21c23a150 call \
--endpoint env:MYSECRET --bucket env:MYSECRET --access-key-id env:MYSECRET --secret-access-key env:MYSECRETfunc (m *MyModule) Example(endpoint *dagger.Secret, bucket *dagger.Secret, accessKeyId *dagger.Secret, secretAccessKey *dagger.Secret) *dagger.Bucketuploader {
return dag.
Bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey)
}@function
def example(endpoint: dagger.Secret, bucket: dagger.Secret, access_key_id: dagger.Secret, secret_access_key: dagger.Secret) -> dagger.Bucketuploader:
return (
dag.bucketuploader(endpoint, bucket, access_key_id, secret_access_key)
)@func()
example(endpoint: Secret, bucket: Secret, accessKeyId: Secret, secretAccessKey: Secret): Bucketuploader {
return dag
.bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey)
}Types
Bucketuploader 🔗
Bucketuploader provides bucket upload artifact capabilities. It expects an S3-compatible bucket via the AWS CLI.
uploadTree() 🔗
UploadTree uploads a directory to the bucket under an explicit prefix, preserving the directory’s internal structure as the key suffix.
Unlike UploadLatest or UploadNightly, which use fixed prefix conventions, UploadTree allows the caller to specify any prefix: useful for one off releases, OCI registry layouts, or nested directory structures with specifc key paths.
Return Type
Void !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| artifacts | Directory ! | - | Directory to upload — internal structure becomes the key suffix |
| prefix | String | - | Bucket key prefix. Use "" to upload at the bucket root. |
Example
dagger -m github.com/papercomputeco/daggerverse/bucketupload@ea0f099e3460fb50812c647745d5ead21c23a150 call \
--endpoint env:MYSECRET --bucket env:MYSECRET --access-key-id env:MYSECRET --secret-access-key env:MYSECRET upload-tree --artifacts DIR_PATHfunc (m *MyModule) Example(ctx context.Context, endpoint *dagger.Secret, bucket *dagger.Secret, accessKeyId *dagger.Secret, secretAccessKey *dagger.Secret, artifacts *dagger.Directory) {
return dag.
Bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey).
UploadTree(ctx, artifacts)
}@function
async def example(endpoint: dagger.Secret, bucket: dagger.Secret, access_key_id: dagger.Secret, secret_access_key: dagger.Secret, artifacts: dagger.Directory) -> None:
return await (
dag.bucketuploader(endpoint, bucket, access_key_id, secret_access_key)
.upload_tree(artifacts)
)@func()
async example(endpoint: Secret, bucket: Secret, accessKeyId: Secret, secretAccessKey: Secret, artifacts: Directory): Promise<void> {
return dag
.bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey)
.uploadTree(artifacts)
}uploadLatest() 🔗
UploadLatest uploads artifacts under both the given version prefix and a “latest” prefix, so that the most recent release is always accessible at a well-known path.
Return Type
Void !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| artifacts | Directory ! | - | Directory containing build artifacts to upload |
| version | String ! | - | Version string used as the bucket path prefix (e.g., "v1.2.3") |
Example
dagger -m github.com/papercomputeco/daggerverse/bucketupload@ea0f099e3460fb50812c647745d5ead21c23a150 call \
--endpoint env:MYSECRET --bucket env:MYSECRET --access-key-id env:MYSECRET --secret-access-key env:MYSECRET upload-latest --artifacts DIR_PATH --version stringfunc (m *MyModule) Example(ctx context.Context, endpoint *dagger.Secret, bucket *dagger.Secret, accessKeyId *dagger.Secret, secretAccessKey *dagger.Secret, artifacts *dagger.Directory, version string) {
return dag.
Bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey).
UploadLatest(ctx, artifacts, version)
}@function
async def example(endpoint: dagger.Secret, bucket: dagger.Secret, access_key_id: dagger.Secret, secret_access_key: dagger.Secret, artifacts: dagger.Directory, version: str) -> None:
return await (
dag.bucketuploader(endpoint, bucket, access_key_id, secret_access_key)
.upload_latest(artifacts, version)
)@func()
async example(endpoint: Secret, bucket: Secret, accessKeyId: Secret, secretAccessKey: Secret, artifacts: Directory, version: string): Promise<void> {
return dag
.bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey)
.uploadLatest(artifacts, version)
}uploadNightly() 🔗
UploadNightly uploads artifacts under the “nightly” prefix.
Return Type
Void !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| artifacts | Directory ! | - | Directory containing build artifacts to upload |
Example
dagger -m github.com/papercomputeco/daggerverse/bucketupload@ea0f099e3460fb50812c647745d5ead21c23a150 call \
--endpoint env:MYSECRET --bucket env:MYSECRET --access-key-id env:MYSECRET --secret-access-key env:MYSECRET upload-nightly --artifacts DIR_PATHfunc (m *MyModule) Example(ctx context.Context, endpoint *dagger.Secret, bucket *dagger.Secret, accessKeyId *dagger.Secret, secretAccessKey *dagger.Secret, artifacts *dagger.Directory) {
return dag.
Bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey).
UploadNightly(ctx, artifacts)
}@function
async def example(endpoint: dagger.Secret, bucket: dagger.Secret, access_key_id: dagger.Secret, secret_access_key: dagger.Secret, artifacts: dagger.Directory) -> None:
return await (
dag.bucketuploader(endpoint, bucket, access_key_id, secret_access_key)
.upload_nightly(artifacts)
)@func()
async example(endpoint: Secret, bucket: Secret, accessKeyId: Secret, secretAccessKey: Secret, artifacts: Directory): Promise<void> {
return dag
.bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey)
.uploadNightly(artifacts)
}uploadFile() 🔗
UploadFile uploads a single file to the bucket under an optional path prefix. This is useful for standalone files like install scripts.
Return Type
Void !Arguments
| Name | Type | Default Value | Description |
|---|---|---|---|
| file | File ! | - | The file to upload |
| prefix | String | - | Bucket path prefix (e.g., "scripts"). When empty the file is placed at the bucket root. |
Example
dagger -m github.com/papercomputeco/daggerverse/bucketupload@ea0f099e3460fb50812c647745d5ead21c23a150 call \
--endpoint env:MYSECRET --bucket env:MYSECRET --access-key-id env:MYSECRET --secret-access-key env:MYSECRET upload-file --file file:pathfunc (m *MyModule) Example(ctx context.Context, endpoint *dagger.Secret, bucket *dagger.Secret, accessKeyId *dagger.Secret, secretAccessKey *dagger.Secret, file *dagger.File) {
return dag.
Bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey).
UploadFile(ctx, file)
}@function
async def example(endpoint: dagger.Secret, bucket: dagger.Secret, access_key_id: dagger.Secret, secret_access_key: dagger.Secret, file: dagger.File) -> None:
return await (
dag.bucketuploader(endpoint, bucket, access_key_id, secret_access_key)
.upload_file(file)
)@func()
async example(endpoint: Secret, bucket: Secret, accessKeyId: Secret, secretAccessKey: Secret, file: File): Promise<void> {
return dag
.bucketuploader(endpoint, bucket, accessKeyId, secretAccessKey)
.uploadFile(file)
}