fastly compute init

Initialize a new Compute package locally.


$ fastly compute init


--authorNoAuthor(s) of the package
--directoryNoDestination to write the new package, defaulting to the current directory
--fromNoLocal project directory, or Git repository URL, or URL referencing a .zip/.tar.gz file, containing a package template, or an existing service ID created from a starter kit
--languageNoLanguage of the package

Global options

--helpNoShow context-sensitive help.
--accept-defaultsNoAccept default options for all interactive prompts apart from Yes/No confirmations
--auto-yesNoAnswer yes automatically to all Yes/No confirmations. This may suppress security warnings
--debug-modeNoPrint API request and response details (NOTE: can disrupt the normal CLI flow output formatting)
--enable-ssoNoEnable Single-Sign On (SSO) for current profile execution (see also: 'fastly sso')
--non-interactiveNoDo not prompt for user input - suitable for CI processes. Equivalent to --accept-defaults and --auto-yes
--profileNoSwitch account profile for single command execution (see also: 'fastly profile switch')
--quietNoSilence all output except direct command output. This won't prevent interactive prompts (see: --accept-defaults, --auto-yes, --non-interactive)
--tokenNoFastly API token (or via FASTLY_API_TOKEN)
--verboseNoVerbose logging


Initialize a new Compute package locally

To initialize a new Compute package you must select a supported language. The language can be provided using the optional --language flag, which supports tab completion hints, or the flag can be omitted and you'll be prompted interactively. The --name flag can also be omitted, which will result in the CLI prompting you interactively.

$ fastly compute init --name example --language rust

Initialize a new Compute package locally using a remote package template

Any Compute examples can be used as a source template for your new package.

$ fastly compute init --from=

Initialize a new Compute package locally in a different directory

We recommend that you change to the new project directory after running this command, before executing further CLI commands.

$ fastly compute init --directory ./example