Documentation
¶
Index ¶
- func CleanUpLocalDevelop(environ []string) error
- func Develop(ctx context.Context, path, keyFile, configFile string) error
- func DevelopCommand(ctx context.Context, path, keyFile, configFile string) (*exec.Cmd, error)
- func LocalDevelop(ctx context.Context, path, configFile, projectID, serviceAccountEmail string) error
- func LocalDevelopCommand(ctx context.Context, path string, configFile string, projectID string, ...) (*exec.Cmd, error)
- func LocalDevelopEnv(ctx context.Context, configFile string, projectID string, ...) ([]string, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func CleanUpLocalDevelop ¶ added in v0.318.0
CleanUpLocalDevelop is meant to be called after the Cloud Run service is shut down locally. It removes the temporary creds-xxxxx.json file.
func Develop ¶
Develop starts the Cloud Run service at the provided Go path with the provided service account and config. Deprecated: Develop uses a service account key which are inherently more risky as they are not often rotated. Use LocalDevelop instead.
func DevelopCommand ¶ added in v0.140.0
DevelopCommand returns an *exec.Cmd pre-configured to start the Cloud Run service at the provided Go path with the provided service account and config. Deprecated: DevelopCommand uses a service account key which are inherently more risky as they are not often rotated. Use LocalDevelopCommand instead.
func LocalDevelop ¶ added in v0.291.0
func LocalDevelopCommand ¶ added in v0.291.0
func LocalDevelopEnv ¶ added in v0.318.0
func LocalDevelopEnv( ctx context.Context, configFile string, projectID string, serviceAccountEmail string, ) ([]string, error)
LocalDevelopEnv sets up the environment variables for running the Cloud Run service locally, with SA impersonation. The environment variables are returned on the format KEY=value and can easily be outputted to a .env file or similar. NOTE: this function creates a temporary creds-xxxxx.json file that is meant to be removed when the service is shut down. Make sure to call CleanUpLocalDevelop after shutting down the service.
Types ¶
This section is empty.