The Fermyon Cloud Plugin
Kate Goldenring
spin
cloud
plugin
Spin is the open source developer tool for building and running serverless applications powered by WebAssembly. In just a minute, you can have a running Wasm application. In a few seconds more, you can deploy it to the Fermyon Cloud, turning a local application into a universally accessible one. This was a part of the Spin story soon after its inception, with simple spin cloud login
and spin cloud deploy
commands added to the CLI to enable logging into Fermyon Cloud and pushing your applications there. While Spin has stabilized with the v1.0
release, the features of Fermyon Cloud continue to grow and evolve. Out of desire to keep the core Spin runtime and CLI stable while also enabling the functionality of Fermyon Cloud to iterate over time, cloud related commands have moved to a separate spin cloud
plugin.
What is a Plugin?
Spin plugins add new functionality or subcommands to Spin without modifying the Spin codebase. Plugins can be added to the Spin plugins repository and then listed and installed using the spin plugins
command. Since plugins have their own versioning system, they can be developed and released independently of Spin, with updates being applied by running spin plugins update && spin plugins upgrade <plugin-name>
How Do I Get the Cloud Plugin
In Spin v1.3
, the core logic of spin login
and spin deploy
were removed from Spin and moved into a spin cloud
plugin. This means that for all versions of Spin v1.3
and beyond the Spin binary no longer contains this functionality; however, as a user, you should not need to take action to get the plugin. The core spin cloud login
and spin cloud deploy
experience that is a part of the stabilized v1
Spin CLI remains. Most likely the plugin is shipped with Spin, as is the case if using the installer script to install Spin. Otherwise, if a user executes a spin cloud
command and the cloud plugin is not installed on their system, Spin will inform the user that the spin cloud
plugin has not been installed and then install the plugin:
$ spin cloud login
The `cloud` plugin is required. Installing now.
Plugin 'cloud' was installed successfully!
Description:
The Fermyon Cloud Plugin
Homepage:
https://github.com/fermyon/cloud-plugin
Copy your one-time code:
1234566
...and open the authorization page in your browser:
https://cloud.fermyon.com/device-authorization
How Do I Get the Latest Cloud Features?
Part of the excitement around a cloud plugin is the ability to release new features for Fermyon Cloud without having to align with the Spin release cadence. Like any plugin, the latest cloud plugin can be fetched by running:
spin plugins update
spin plugins upgrade cloud
Spin will soon have support to notify you of available plugin upgrades, so you will know as soon as new features are released in your favorite plugins. Additionally, for the cloud plugin, reference the cloud command documentation to explore the latest subcommands.
What is Coming Soon?
In conjunction with the Spin v1.3 release, Fermyon announced support for dynamically configuring secrets and variables in Spin applications in the cloud. Now, you can use the spin cloud variables
command to list, set, and delete variables, unlocking the ability to configure application secrets, update API endpoints, and more.
In the future, we expect the cloud command to continue to expand to support other application management actions.
Let us know what other features you would like in the cloud plugin by creating an issue in the fermyon/cloud-plugin
repository.
Conclusion
We are excited for how the cloud plugin creates an opportunity to accelerate what Spin applications can do in the Cloud and not just Fermyon Cloud. The Fermyon Cloud is just one of many places to deploy Spin applications. Already, Spin apps are being run on Kubernetes, such as with Azure Kubernetes Service’s WASI node pools. When we were first designing the cloud plugin, we considered trying to make a generic interface that any provider could implement. However, we found this very prescriptive, especially given all the environments that serverless Wasm applications are deployed to today. Instead, we hope other providers will create plugins that suit their platforms and we are happy to collaborate on the plugin creation.