title | description | position | category |
---|---|---|---|
使用s工具进行克隆函数 |
使用s工具进行克隆函数 |
13 |
概述 |
在s工具中有一个s sync命令,我们可以通过这个命令实现快速克隆函数。查看详情,也可以通过执行s cli fc sync -h
查看帮助信息
Sync
Synchronize online resources to offline resources
Usage
s sync <options>
Options
-f, --force boolean Mandatory overwrite code file
--function-name string Specify the alicloud fc function name.
--region string Specify the region of alicloud.
--service-name string Specify the alicloud fc service name.
--target-dir string Specify storage directory(default: current dir)
--trigger-name string Specify the alicloud fc trigger name, you can set names by using multiple
trigger-name option, eg: --trigger-name triggerA --trigger-name triggerB.
--type string Operation type, code/config/all(default: all)
Global Options
-a, --access string Specify key alias
--debug string Output debug informations
-h, --help string Help for command.
Examples with Yaml
$ s sync
$ s <ProjectName> sync
$ s sync --region cn-hangzhou --service-name myService
$ s exec -- sync --region cn-hangzhou --service-name myService
Examples with CLI
$ s cli fc sync --region cn-shanghai --service-name myService --type config
s cli fc sync --region cn-hangzhou --service-name sync-test --function-name sync-test -a default
至此,整个克隆示例完成