Este tópico descreve os comandos relacionados a serviços na Function Compute Command Line Interface (fcli).
Pré-requisitos
Execute fcli shell no diretório que contém o arquivo executável para entrar no modo interativo.
Criar um serviço (mks)
-d stringou--description string: descrição do serviço.-p stringou--log-project string: projeto de log associado ao serviço.-l stringou--log-store string: Logstore associado ao serviço.-r stringou--role string: função associada ao serviço.
>>> mks myService //Creates a service without any advanced settings.
>>> mks myService -d 'my description' -p my-log-project -l my-log-store -r acs:ram::myID:role/myRoleName //Creates a service, in which the description is my description, the log project is my-log-project, the Logstore is my-log-store, and the role is myRoleName.
Atualizar um serviço (ups)
Os parâmetros deste comando são idênticos aos do comando mks.
-d stringou--description string: descrição do serviço.-p stringou--log-project string: projeto de log associado ao serviço.-l stringou--log-store string: Logstore associado ao serviço.-r stringou--role string: função associada ao serviço.
>>> ups myService -d 'my description' -p my-log-project -l my-log-store -r acs:ram::myID:role/myRoleName //Updates the service, in which the description is my description, the log project is my-log-project, the Logstore is my-log-store, and the role is myRoleName.