alpacon server create
Generate installation instructions to register a server.
Usage
alpacon server create [flags]
Key facts
- Choose
token-installoransibleas the registration method. - Provide
--platformand--tokenor--new-tokenfor non-interactive use.
Flags
Registration
| Flag | Type | Description | Default |
|---|---|---|---|
-m, --method | string | Registration method: token-install or ansible. | token-install |
-p, --platform | string | Target OS: debian, rhel, suse, darwin, or windows. suse is unavailable with --method ansible. | — |
Token and server
| Flag | Type | Description |
|---|---|---|
-t, --token | string | Existing registration token name. |
--new-token | string | Create a new registration token with this name. |
-n, --name | string | Server name; uses the hostname if omitted. |
Output and help
| Flag | Type | Description | Default |
|---|---|---|---|
--json | bool | Output the installation guide as structured JSON instead of Markdown. | false |
--output | string | Output format: table or json. Inherited by all commands. | table |
-h, --help | bool | Show command help. | false |
Examples
Generate an installation guide interactively
alpacon server createGenerate a guide for a Debian server with an existing token
alpacon server create --platform debian --token prod-tokenSet the server name explicitly (the hostname is used if not set)
alpacon server create --platform rhel --token prod-token --name my-serverGenerate a guide for an openSUSE or SLES server
alpacon server create --platform suse --token prod-tokenGenerate a guide for a macOS server
alpacon server create --platform darwin --token prod-tokenGenerate an Ansible playbook command instead of a token-install guide
alpacon server create --method ansible --platform debian --token prod-tokenOutput the guide as structured JSON
alpacon server create -m ansible -p windows -t prod-token --jsonRegistration methods
- token-install (default): the guide includes the Alpamon register command to run on your server.
- ansible: the guide produces an
ansible-playbookcommand using thealpacax.alpaconcollection, so you can register one or many servers from a control node.
Supported platforms: debian, rhel, suse (openSUSE and SLES), darwin, windows. suse needs alpacon CLI 1.14.2 or later and works only with the token-install method.
Non-interactive mode
When --platform and either --token or --new-token are provided, the command runs non-interactively. This is useful for scripts and automation pipelines. Use --token to reference an existing registration token by name, or --new-token to create a new one on the fly. See Registration token management for managing tokens.