Let's get started
- Install Spin
- Log in to the Fermyon Cloud
- Clone the Quickstart Repo
- Deploy the Application
- Success
- Next Steps
This is the open beta of the Fermyon Cloud. For more info about the limitations and support, please see read the FAQ.
This guide will get you up and running in the Fermyon Cloud in less than two minutes. To do so, we’ve already made a Spin application ready for you to deploy to the cloud.
Install Spin
Download the spin
binary using the install.sh
script hosted on this site:
$ curl -fsSL https://developer.fermyon.com/downloads/install.sh | bash
Then move the spin
binary somewhere in your path, so you can run it from anywhere. For example:
$ sudo mv ./spin /usr/local/bin/spin
Download the spin
binary using the install.sh
script hosted on this site:
$ curl -fsSL https://developer.fermyon.com/downloads/install.sh | bash
Then move the spin
binary somewhere in your path, so you can run it from anywhere. For example:
$ sudo mv ./spin /usr/local/bin/spin
Download the Windows binary release of Spin from GitHub.
Unzip the binary release and place the spin.exe
in your system path.
Learn more
Spin is an open-source project used for creating, developing, building, running, and deploying Spin applications. It is both a CLI tool and a runtime, and provides SDKs for a variety of programming languages, including, but not limited to, Rust, TinyGo, and C#.
The Spin project provides installers that are supported on Linux (amd64), macOS (amd64 and arm64), and Windows(amd64).
The Spin documentation is a good starting place to learn more about using the framework to develop applications.
Log in to the Fermyon Cloud
Now, let’s log in to the Fermyon Cloud. You will be using your GitHub user account to sign in:
$ spin login
Copy your one-time code:
XXXXXXXX
...and open the authorization page in your browser:
https://cloud.fermyon.com/device-authorization
Waiting for device authorization...
Device authorized!
This command will generate an authentication code for your current device to be authorized against the Fermyon Cloud. Follow the instructions in the prompt to complete the authorization process.
Learn more
The default behavior of spin login
is to authenticate with the Fermyon Cloud. The command can authenticate against any instance of the Fermyon Platform.
Clone the Quickstart Repo
To make this easy, we’ve already compiled a Webassembly module and created a Spin application for you to deploy.
Let’s go ahead and clone the https://github.com/fermyon/cloud-start repository to your computer to retrieve that application:
$ git clone https://github.com/fermyon/cloud-start && cd cloud-start
This command clones the repository into a local directory named cloud-start
, and then enters that directory.
Learn more
To write your Spin application, you would start by using the command spin new [template name] [project name]
. This gives you the option to select a template based on your preference of programming language and trigger for your module - e.g., spin new rust-http my_rust_http_trigger
.
The Spin quickstart guides you through creating a Spin application from scratch.
Deploy the Application
Let’s deploy the application:
$ spin deploy
The spin
command will run using the Spin binary in your system path and read the Spin application definition file spin.toml
in the current (cloud-start
) directory to know what application to deploy.
Learn more
Deploying a Spin application to the Fermyon Cloud includes packaging the application and all the required files, uploading it to an OCI registry, as well as instantiating the application on the cloud.
You can learn more about the deployment process here.
Success
This is what a successful Spin application deployment on Fermyon Cloud looks like:
Uploading cloud_start version 0.1.0+XXXXXXXX to Fermyon Cloud...
Deploying...
Waiting for application to become ready... ready
Available Routes:
cloud-start: https://cloud-start-XXXXXXXX.fermyon.app (wildcard)
You can CTRL+Click on the link in the terminal to visit the web application you just deployed.
Congratulations, you’ve now deployed your first Spin application to the Fermyon Cloud!
Next Steps
- Log in to the Fermyon Cloud to see your deployed applications and manage them
- Go and check out how to build a Spin application from scratch
- Dive into learning more about the Fermyon Cloud
- Learn how to delete your Spin application
- Find known issues and file new ones with this GitHub repository