nself clean
nself clean — ɳSelf documentation.
Remove generated artifacts (docker-compose.yml, nginx configs, build cache).
Synopsis
nself clean [flags]
Description
nself clean removes generated artifacts that are recreated by nself build: docker-compose.yml, the nginx/sites/ configuration files, the .nself/cache/ build cache, and Docker’s build cache (exec.cachemount type). It does not touch Docker volumes, container data, or user-managed files.
The operation is non-destructive (all data is preserved), so no confirmation prompt is required. Run nself build afterward to regenerate all artifacts. To also remove containers and data volumes, use nself reset instead.
Flags
| Flag | Default | Description |
|---|---|---|
--help, -h |
none | Show help |
Examples
# Remove generated build artifacts
nself clean
# Regenerate them afterward
nself build
What is removed:
docker-compose.ymlnginx/sites/configuration files.nself/cache/(build cache)- Docker build cache (
exec.cachemounttype)
What is preserved:
.envand all.env.*variant files- Docker volumes and container data
- Your application source code