CLI guided learning
BetaCloudflare CLI tutor, or cf-tutor
, is a guided learning experience within your terminal. If you are unfamiliar with Workers, or are new to command line interface (CLI) based development, cf-tutor offers an introduction on how to use Workers with other Cloudflare products through your terminal.
cf-tutor
is currently a beta application in pre-release. To download the application, you can use the git clone
in your terminal, or download the application from the releases page on the project repo.
- Sign up for a Cloudflare account ↗.
- Install
Node.js
↗.
Node.js version manager
Use a Node version manager like Volta ↗ or nvm ↗ to avoid permission issues and change Node.js versions. Wrangler, discussed later in this guide, requires a Node version of 16.17.0
or later.
- Open a terminal window.
- In your terminal, navigate to the folder you wish to install cf-tutor. You can change directory by using the
cd
command followed by the folder path. You can either enter the full path such ascd Documents/Projects/
or you can usecd
multiple times to go folder by folder. To see the files and folders in the directory you are currently in, runls
. - Run the command
git clone https://github.com/db-cloudflare/cf-tutor.git
to download cf-tutor. - Run the command
cd cf-tutor
to enter the application folder. - Run the command
npm i
to install all dependendant packages. - Once the dependencies have installed, run
npm start
to run the application
The following steps require an SSH key. Vist GitHub documentation on Connecting with SSH to learn more ↗
- Open a terminal window.
- In your terminal, navigate to the folder you wish to install cf-tutor. You can change directory by using the
cd
command followed by the folder path. You can either enter the full path such ascd Documents/Projects/
or you can usecd
multiple times to go folder by folder. To see the files and folders in the directory you are currently in, runls
. - Run the command
git clone git@github.com:db-cloudflare/cf-tutor.git
and enter your SSH key to download cf-tutor. - Run the command
cd cf-tutor
to enter the application folder. - Run the command
npm i
to install all dependendant packages. - Once the dependencies have installed, run
npm start
to run the application
- Open cf-tutor releases ↗.
- Download the cf-tutor.zip file and extract the folder inside it into your desired location.
- In your terminal, navigate to the cf-tutor folder. You can change directory by using the
cd
command followed by the folder path. You can either enter the full path such ascd Documents/Projects/cf-tutor
or you can usecd
multiple times to go folder by folder. To see the files and folders in the directory you are currently in, runls
. - Run the command
npm i
to install all dependendant packages. - Once the dependencies have installed, run
npm start
to run the application.
To do more:
- Visit the Cloudflare dashboard ↗ for simpler editing.
- Learn how to test and debug your Workers.
- Read about Workers limits and pricing.