This document describes how to use the SCF component provided by Serverless Cloud Framework to quickly create and deploy an SCF project. For more information on components and how to use them, please see Components Overview
Run the following command to quickly create a function in the Node.js language:
scf init scf-demo
Note:
scf-demo
in the command is the Node.js template by default, and you can replace it with function templates in other languages, such asscf-golang
,scf-php
, andscf-python
.
Run the following command in the scf-demo
directory to deploy the function:
scf deploy
A QR code will pop up. Please scan it to authorize and start deployment. After successful deployment, SCF resources will be automatically created.
Note:If authentication fails, please authorize as instructed in Account and Permission Configuration.
Run the following command to view the information of the deployed SCF resources:
scf info
Run the following command to remove the deployed SCF resources:
scf remove
Was this page helpful?