Skip to content
Daml

Publishing Components

Publishing Components

Note

This functionality is available in DPM version 1.0.14 or later (or bundled with SDK 3.5 or later)

To share or use your Component in various projects, you can publish it to a repository.

dpm publish component oci://<destination>:<strict semantic version> \
    --platform generic="/path/to/component/directory"

for example:

dpm publish component oci://example.com/my/components/foo:1.0.0 \
    --platform generic="~/component-foo"

This will publish version 1.0.0 of foo as OCI to example.com/my/components/foo:1.0.0

For multi-platform components, you can instead provide a directory for each platform. For example:

dpm publish component oci://example.com/my/components/foo:1.0.0 \
    --platform linux/arm64="/some/directory" \
    --platform windows/amd64="/another/directory"

See the dpm publish component --help command for more available options.

Also, you can view the published versions (and tags) of a component

dpm tags oci://example.com/my/components/foo

For information on how to use the published component in your project, see the section on using components