docs/versioned_docs/version-0.16.3/ci/quickstart/publish.mdx
import Tabs from "@theme/Tabs"; import TabItem from "@theme/TabItem";
The end stage of the example pipeline is the publish stage, which publishes the container image to a registry.
Just as you can call Dagger Functions individually from the CLI, you can also call (and combine) them using a programming language. This Dagger Function is an example. It is a higher-level function which orchestrates the Dagger Functions in previous sections and the core Dagger API to:
:::tip COMBINING DAGGER FUNCTIONS
There are various reasons why you might want to write Dagger Functions that call other Dagger Functions. A common reason is that when developing locally, it's quicker and easier to trigger your pipeline using a single command (dagger call publish ...) instead of multiple commands (dagger call test ... && dagger call build ... && ...).
:::
Call the Dagger Function:
dagger call publish --source=.
You should see the application being tested, built, and published to the ttl.sh container registry:
You can test the published container image by pulling and running it with docker run:
:::tip FUNCTION CHAINING Function chaining works the same way, whether you're writing Dagger Function code using a Dagger SDK or invoking a Dagger Function using the Dagger CLI. The following are equivalent:
<Tabs groupId="language"> <TabItem value="Go">