Skip to main content

Initialize the Project

Using the initialize command, you can create a Cloud Run service project.

Basic Usage

tcb cloudrun init

Usage Example:

# Interactive Initialization. The CLI will guide you through configuring settings such as the environment and service name.
tcb cloudrun init

# Initialize the Project with Specified Environment and Service Name
tcb cloudrun init -e env-123456 -s my-service

# Initialize Using a Template and Specify the Target Path
tcb cloudrun init --template nodejs --targetPath ./my-project

# Initialize a New Project with Full Configuration
tcb cloudrun init -e env-123456 -s api-service --template express --targetPath ./backend

Command Line Parameters

ParameterDescriptionRequired
-e, --env-idEnvironment IDNo
-s, --serviceNameService nameNo
--templateTemplate nameNo
--targetPathTarget path for project initialization (absolute or relative path, default: current directory)No
-h, --helpDisplay command help informationNo

Precautions

  • If no parameters are specified, the command will guide you through the configuration in interactive mode
  • If the target path does not exist, it will be automatically created
  • Using templates can rapidly set up standard project structures