Initializing SFP server
Availability
✅
❌
From
December 24
The sfp server init
command is used to set up and configure an SFP server instance. This command creates the necessary directory structure, generates configuration files, and initializes the database.
Basic Usage
This command will:
Create a directory structure for your tenant at
./sfp-server/tenants/my-app
Generate Docker Compose and Caddy configuration files
Collect required secrets (prompting if needed)
Initialize the Supabase database with required schema
Start the server containers
Create a default admin user
Command Options
Required Parameters
--tenant
: Name of the tenant (required, must be lowercase alphanumeric with hyphens)
Environment Configuration
--mode
: Server mode, either 'dev' or 'prod' (default: 'prod')--domain
: Domain name for the server (required in prod mode)
Infrastructure Configuration
--worker-counts
: Number of workers for critical,normal,batch queues (comma separated, default: 1,1,1)--base-dir
: Base directory for the server (default: './sfp-server')
Secrets Configuration
--secrets-provider
: Type of secrets provider to use (options: 'custom', 'infisical')--infisical-token
: Authentication token for Infisical--infisical-workspace
: Workspace ID in Infisical
Other Options
--interactive
: Run in interactive mode to prompt for secrets (default: false)--force
: Overwrite existing tenant configuration if it exists--config-file
: Path to JSON config file containing server configuration
Example Usage
Development Mode
Production Mode with Domain
Using Configuration File
Example configuration file:
Post-Initialization
After successful initialization, the command outputs:
Tenant URL and access details
Available management commands
Service status information
You can manage the initialized server using other sfp server
commands:
Note: For production deployments, ensure you have configured your domain DNS settings and have necessary SSL certificates before initialization.
Warning: The
--force
flag will overwrite existing configurations. Use with caution in production environments.
Last updated