Juju SDK Documentation

The Charmed Operator Software Development Kit (SDK) is a toolkit for packaging applications—in a special format called Charmed Operators (‘charms’)—for the cloud. It is a component of the Charmed Operator Framework Juju and it consists of the command line tool Charmcraft (charmcraft) and the Python charmed operator framework Ops (ops).

The SDK provides commands and templates to package both Kubernetes and non-Kubernetes applications in one standard format with the extension “.charm”. These can be subsequently deployed using Juju’s Charmed Operator Lifecycle Manager (OLM).

As such, the SDK makes it quick and easy to make applications of any type ready for the cloud.

For DevOps, Juju’s SDK simplifies workflow; for CIOs, it helps reimagine solutions, as it lowers the barrier for including new applications.

For a collection of existing charms, see Charmhub. To deploy and manage an existing or new charm, see the Charmed Operator Lifecycle Manager (OLM).

In this documentation

Get started - a hands-on introduction to the Juju SDK for new users
How-to guides
Step-by-step guides covering key operations and common tasks
Concepts - discussion and clarification of key topics
Technical information - specifications, APIs, architecture

Project and community

The Juju SDK is an open source project that warmly welcomes community projects, contributions, suggestions, fixes and constructive feedback.


Level Path Navlink
0 Juju SDK documentation
0 tutorials Tutorials
build-and-deploy-minimal-machine-charm Build and deploy a minimal machine charm
build-and-deploy-minimal-kubernetes-charm Build and deploy a minimal Kubernetes charm
Build a Charmed Operator for Kubernetes (video)
build-a-minimal-operator Build your first Kubernetes operator
0 how-to How-to guides
setup Set-up
create-an-ubuntu-virtual-machine-with-multipass     Create an Ubuntu virtual machine with Multipass
dev-setup Development setup
install-charmcraft Install Charmcraft
charmcraft-config Configure Charmcraft
remote-env-auth Authenticate Charmcraft in remote environments
hello-world Hello, world
manage-charms Manage charms
initialise-your-charm Initialise your charm
change-step-behavior-in-a-charm Change step behavior when creating a charm
build-your-charm Pack your charm
pack-your-reactive-based-charm-with-charmcraft Pack your reactive-based charm with Charmcraft
workloads Run workloads with your charm
pack-your-hooks-based-charm-with-charmcraft Pack your hooks-based charm with Charmcraft
logging Configure logging in your charm
config Handle charm configuration
testing Test your charm
write-an-integration-test-for-a-charm Write an integration test for a charm
deploy-your-charm Deploy your charm
charm-documentation Document your charm: The README file
publishing Publish your charm to Charmhub
add-docs-to-your-charmhub-page Add docs to your charm page on Charmhub
create-an-icon-for-your-charm Create an icon for your charm
interact-with-pebble Interact with Pebble
actions Handle actions
resources Manage charm resources
define-a-resource-for-your-charm Define a resource for your charm
associate-a-resource-to-your-charm Associate a resource to your charm
publishing-resources Publish a resource to Charmhub
attach-a-resource-to-a-charm-at-release-time Attach a resource to a charm at release time
access-a-resource-from-your-charm Access a resource from your charm
manage-libraries Manage charm libraries
find-and-use-a-charm-library Find and use a charm library
create-and-publish-a-charm-library Create and publish a charm library
document-your-charm-library Document your charm library
manage-bundles Manage charm bundles
create-a-charm-bundle Create a charm bundle
configure-a-charm-bundle Configure a charm bundle
set-charm-channels-within-a-bundle Set charm channels within a bundle
set-charm-constraints-within-a-bundle Set charm constraints within a bundle
set-charm-options-within-a-bundle Set charm options within a bundle
integrate-a-local-charm-into-a-bundle Integrate a local charm into a bundle
add-an-overlay-bundle Add an overlay bundle
append-an-overlay-bundle-to-a-base-bundle Append an overlay bundle to a base
resolve-a-relative-path-inside-a-bundle Resolve a relative path inside a bundle
remove-an-application-from-a-bundle Remove an application from a bundle
replace-machines-in-a-bundle Replace machines in a bundle
modify-relations-inside-a-bundle Modify relations inside a bundle
add-machine-specifications-to-a-bundle Add machine specifications to a bundle
bind-endpoints-within-a-bundle Bind endpoints within a bundle
specify-application-expose-parameters-within-a-bundle Specify application expose parameters within a bundle
use-charm-resources-in-a-bundle Use charm resources in a bundle
recycle-machines-in-a-bundle Recycle machines in a bundle
add-a-placement-directive-to-a-bundle Add placement directives to a bundle
add-storage-directives-to-a-bundle Add storage directives to a bundle
set-up-subordinate-charms-inside-a-bundle Set up subordinate charms inside a bundle
compare-a-bundle-to-a-model Compare a bundle to a model
pack-a-charm-bundle Pack a charm bundle
deploy-a-charm-bundle Deploy a charm bundle
publish-a-charm-bundle-to-charmhub Publish a charm bundle to Charmhub
0 reference Reference
charmcraft-cli-commands Charmcraft CLI commands
charmcraft-analyze analyze
charmcraft-clean clean
charmcraft-close close
charmcraft-create-lib create-lib
charmcraft-fetch-lib fetch-lib
charmcraft-init init
charmcraft-list-lib list-lib
charmcraft-login login
charmcraft-logout logout
charmcraft-names names
charmcraft-pack pack
charmcraft-publish-lib publish-lib
charmcraft-register register
charmcraft-register-bundle register-bundle
charmcraft-release release
charmcraft-resource-revisions resource-revisions
charmcraft-resources resources
charmcraft-revisions revisions
charmcraft-status status
charmcraft-upload-resource upload-resource
charmcraft-upload upload
charmcraft-version version
charmcraft-whoami whoami
ops-classes Ops classes
Tools, entities, processes
charmcraft charmcraft
charmcraft-deprecations Charmcraft deprecation notices
charm-bundles Bundle
kubernetes-vs-non-kubernetes-bundles Kubernetes vs. non-Kubernetes bundles
charmed-operators Charmed operator (‘charm’)
charm-types-by-deployment-type Charms, by deployment type
charm-types-by-development-type Charms, by development type
charm-anatomy Charm anatomy
event–hook Event / hook
events Core lifecycle events
charm-libraries Library
the-location-of-a-charm-library-inside-a-charm The location of a charm library inside a charm
library-index Popular charm library index
ops ops
pebble Pebble
relations Relation
about-resources Resource
storage Storage
Other reference
a-charms-life A charm’s life
charmcraft-analyze Analyzers and linters
metadata-reference Charm metadata reference
debugging Debugging
constructs Framework constructs
hook-tools Hook tools
leadership Leadership
integration-testing-cookbook Integration testing cookbook
stored-state-uses-limitations StoredState: Uses, Limitations
api-reference API reference
libraries Libraries
yaml-anchors-and-aliases YAML anchors and aliases
0 explanation Explanation
deferring-events-details-and-dilemmas Deferring events: Details and dilemmas
history Charming history
assumes Assumes
styleguide Charm development best practices
naming Charm naming guidelines
roadmap Roadmap


Mapping table
Location Path
/docs/sdk/charm-types /docs/sdk/charm-types-by-destination-type
/docs/sdk/setting-up-charmcraft /docs/sdk/install-charmcraft
/docs/sdk/bundles /docs/sdk/publish-a-charm-bundle-to-charmhub
/docs/sdk/bundle-reference /docs/sdk/manage-bundles
/docs/sdk/charmcraft-libraries /docs/sdk/manage-libraries

There’s a few bugs in this document:

Under the “Kubernetes Charm” header
When a model is created on Kubernetes, a corresponding Kubernetes namespace is created.

This should read “When a model is created in juju, a corresponding…”

1 Like

Thanks, will fix now.

Although the navigation menu here correctly links “Github” to https://github.com/canonical/operator, when rendered it is linked to https://juju.is/canonical/operator, which is a 404.

Hmm that’s annoying, I wonder if that’s changed recently :confused:

@toto do you know how to solve that? Trying to link to an external link the nav?

@jkfran Can you please take a look here?

I opened a bug on it a few days back, I believe it is being worked on - https://github.com/canonical-web-and-design/juju.is/issues/258

We had a bug in the previous version of our documentation parser with external links. It should be fine now :slight_smile:

1 Like

Hi, here are sum suggestions/fixes/imporvements on the doc.

Hi Kos - top reviewing today!

Have made some adjustments here. I’ve left the charmed operators link pointing at the docs homepage as it has a brief definition and link off to other places with more context. Will review when I find a better end destination!

I made some additional clarifying edits about what a unit is compared to an application as a corollary to the “scale to n replicas” example.