CLI Reference
Build
The blokctl build command compiles your nanoservice source code into a deployable artifact, preparing it for execution or deployment. This step ensures your code, dependencies, and configuration are packaged correctly according to the nanoservice-ts project structure.
Whether you're building from the default project directory, a custom location, or directly within the current folder, the CLI offers flexible options to match your development workflow. Use it as part of your standard development, testing, or deployment process.
Once the build is complete, you're ready to deploy your nanoservice using the deploy command.
Build Blok
Syntax
npx blokctl build [options]Compiles and packages a nanoservice from source code into a deployable artifact.
Options
| Option | Alias | Type | Description | Default |
|---|---|---|---|---|
--directory | -d | string | Source directory path | ./nanoservice-ts |
--help | -h | boolean | Show help | false |
Commands
| Command | Description |
|---|---|
. | Build in current directory |
Examples
Build in default directory:
npx blokctl buildBuild in specific directory:
npx blokctl build -d ./my-nanoserviceBuild in current directory:
npx blokctl build .