raclette CLI
The raclette CLI provides various commands to support local development, container management, and project scaffolding for microservice-based applications.
📦 Installation
Once raclette is installed and configured in your project, you can run CLI commands using:
yarn <command>🔧 Available Commands
yarn dev
Starts the local development environment using Docker Compose or optionally runs services directly.
Options:
-d, --directRun services directly (not in containers).-q, --quietRun Docker Compose in detached mode without following logs.--filter <services>Filter logs to specific services (comma-separated). Default:frontend,backend.--force-rebuildForce rebuild of Docker images, even if no files changed.
Example:
yarn dev --filter frontendyarn down
Stops running Docker Compose services.
Options:
--keep-sharedStops only project-specific services, keeping shared services (like MongoDB or Redis) running.
Example:
yarn down --keep-sharedyarn restart [services...]
Restarts one or more specific Docker services by name.
Example:
yarn restart frontend backendyarn update [target]
Updates project dependencies by running internal package update scripts inside containers.
Arguments:
target: One offrontend,backend, orboth. Default:both.
Example:
yarn update backendyarn build
Builds the raclette project for production.
This generates a production-specific docker-compose file and a production tsconfig.json.
Example:
yarn buildyarn add-package <target> <package...>
Adds one or more npm packages to a specific project target.
Arguments:
target: One offrontend,backend, orboth.package: One or more package names to install.
Options:
--devInstall as a development dependency.--no-updateSkip automatic dependency update after adding the package(s).
Examples:
yarn add-package frontend lodash
yarn add-package both eslint --devyarn rebuild [services...]
Rebuilds Docker images for specified services. If no services are passed, raclette detects file changes and rebuilds affected services automatically.
Example:
yarn rebuild frontendyarn init
Initializes a new raclette project (stubbed command for future scaffolding features).
Example:
yarn init🧠 Tips
- If you add new packages, consider running
yarn updateor restarting services withyarn restart frontend backendto apply changes. - For complete rebuilds, use:bash
yarn dev --force-rebuild