ABBY CAREY: Cloud Code is a set of extensions
for the most popular development tools
in the market, the JetBrains family of IDEs,
such as IntelliJ and Visual Studio Code.
In this video, we'll cover the navigation and capabilities
of Cloud Code using the VS Code version.
Cloud Code speeds up your development
by streamlining common workflows for Python, Go, Node.js,
and Java applications, merging non-trivial tasks
into a simple user interface right in your IDE.
This means no more switching between your command line,
Cloud Console, and code editor.
Tasks, like going through the loop of building,
pushing, deploying, and debugging your application,
can be both burdensome and error-prone.
Cloud Code handles that for you.
A key goal of Cloud Code is to enable continuous development
by automating processes.
For example, you can rapidly iterate on a live Kubernetes
cluster or add a Google Cloud API to your application
from your IDE.
The first thing you'll notice when you installed Cloud Code
is the Welcome page.
This provides a summary of the key supported features
and also has a direct link to creating a new project from one
of our starter templates.
Let's take a look at what Cloud Code adds to the VS Code UI.
A few icons have been added to the VS Code activity bar.
Each icon focuses on a separate task within Cloud Code.
If a certain task doesn't apply to your workflow,
you can hide it by right-clicking it and selecting
Hide.
There's also the addition of the Cloud Code status bar,
seen at the bottom of VS Code.
From here, you can access quick actions,
like running and creating a new application.
Cloud Code commands have also been
added to the command palette.
You can access them by pressing Command-Shift-P and typing
in Cloud Code.
Let's take a look at the workflows Cloud Code supports.
First, we have Cloud Code for Kubernetes.
I'll create a new Kubernetes app using one of the templates.
Cloud Code lets you run, debug, and view the logs
of your Kubernetes apps.
This app is ready to go, so let's try running and debugging
it.
To deploy this app, all I need to do
is click the Cloud Code status bar
and select Run on Kubernetes.
Once the deployment is finished, click the link
from the log to view your app running
on your local Kubernetes cluster.
To debug your app, view your code and place a breakpoint.
Go back to the status bar and select Debug on Kubernetes.
Once you view your app and trigger the breakpoint,
VS Code's debugger activates, allowing
you to step through your code.
If we head to the Cloud Code for Kubernetes view,
you'll find the Kubernetes Explorer.
The Kubernetes Explorer lets you visualize all the resources
within your cluster.
You can see information like the IP address of your services
and the ports they use.
This means that you don't have to remember all the core CLI
commands to find this info.
Right-clicking on Resources provides contextual links
for actions, such as viewing the logs from a pod
to opening a connected terminal, all from within VS Code.
You can also create a new cluster from here.
Next, there's Cloud Code for Cloud Run.
Cloud Run is our fully managed serverless product
with auto-scaling that scales down to 0.
As you can see, my Google Cloud project already
has a couple Cloud Run services that are displayed
in the Cloud Run Explorer.
With Cloud Code, you can deploy a new containerized app
to Cloud Run and view the logs for your Cloud Run services.
You can also test things out locally
before you deploy by running and debugging your service on Cloud
Code's Cloud Run emulator.
Finally, there's Cloud APIs.
All Google Cloud APIs are listed here.
If you select an API, you're able to quickly enable
it and follow the provided install instructions.
After that, you're ready to use it with your application.
YAML authoring assistance is another pillar of Cloud Code.
Cloud Code supports a number of configuration files,
including Kubernetes resources like Config Connector and Cloud
Build configurations.
It also supports over 300 custom resource definitions.
Here's a quick example of what YAML authoring assistance looks
like for a Kubernetes config file.
By pressing Control-Space, I get a variety of snippets
to pick from.
After picking one, I can tab through the sections
I need to fill in.
By pressing Control-Space again, I get suggestions.
Linting catches syntax errors, and hovering
over configurations provides inline documentation.
In conclusion, Cloud Code is a tool
that speeds up non-trivial, tedious tasks when developing
Cloud native applications.
It also reduces friction when creating YAML configuration
files.
To learn more about what you can do with Cloud Code,
head to this link.
Also check out the description below for more resources.
We'll go over other scenarios in future videos.
Until next time.