Skip to content
MCP Servers
Skill

/deploy-to-vps

Deploy an existing project to a Hostinger VPS (KVM plans): sets up SSH key access, applies a Hostinger firewall group, runs Docker Compose projects through the Docker Manager where the server has it, or over SSH on any server, points a domain at the server, takes a snapshot

From plugin
api-mcp-server
17325 skills

Claude Code

$ npx -y skills add hostinger/api-mcp-server --skill deploy-to-vps --agent claude-code

SKILL.md

deploy-to-vps.SKILL.md
name: deploy-to-vps
description: "Deploy an existing project to a Hostinger VPS (KVM plans): sets up SSH key access, applies a Hostinger firewall group, runs Docker Compose projects through the Docker Manager where the server has it, or over SSH on any server, points a domain at the server, takes a snapshot before risky changes and verifies the result from outside. Triggers: deploy this to my VPS, run this docker-compose on my Hostinger server, put my app on the server, set up nginx and SSL on my VPS, point my domain to my VPS, redeploy on the VPS, add my SSH key to the VPS."

Deploy to VPS

Ship a project that already exists — on disk or in a Git repository — to a Hostinger VPS in state `running`. Buying, setting up or reinstalling a server is the `provision-vps` skill; a server that is down or misbehaving is `troubleshoot-vps`.

The public API cannot run a command on the server. Packages, services, web servers, certificates and files are handled over SSH or in the hPanel browser terminal, so step 2 comes first whenever a shell is needed.

Calling the operations

  • Read the `inputSchema` that `search` returns before the first call of each operation. If a name below is rejected as unknown, `search` for what the step does (e.g. "add ssh key to virtual machine").
  • Only the public operations that `search` returns can be called. Hostinger Agent tools in hPanel (running commands, resetting SSH or the guest firewall, disk cleanup) are not available here; when a step needs them, send the user to hPanel.
  • Batch reads with `multi-execute`; values pass between steps as `$steps.<i>.<path>`. A batch stops at its first failure. The Hostinger Connector runs `vps` and `dns` as separate servers, so a batch chains operations from one of them only.
  • `Too Many Attempts` is the API rate limit: wait about a minute, then retry that call once, and send no other calls meanwhile. `[VPS:9999] Request failed` (HTTP 500) is usually temporary: retry a read once later. Never resend a change that failed with 500 straight away: it may have gone through, so check the outcome with the matching read or `vps_actions_list` first, and tell the user what you found.
  • A VPS runs one action at a time. Most operations that change it return an action (firewall sync and delete answer `Request accepted` instead; check those with the matching read operation): poll `vps_actions_get` with its `id`, waiting longer between checks, until `state` is `success` or `error` (`created`, `sent`, `delayed`, `started` are still running). Do not send another change while `vps_virtual-machines_get` shows `actions_lock: locked`. An action in `error` keeps the VPS locked and needs Hostinger support.
  • Confirm with the user before: `vps_snapshots_create` (it replaces the existing snapshot), `vps_docker_create` on a project name that already exists (it replaces the project), `vps_docker_stop`, `vps_docker_delete` (removes containers, networks, volumes and images), and `dns_records_update` with `overwrite: true`. Reinstalling is never part of a deploy — hand over to `provision-vps`.
  • SSH keys: use `vps_ssh-keys_*`; the account-level `vps_public-keys_*` operations are deprecated. Firewall sync: use `vps_firewall_sync-to-all-assigned-v-ms`; the single-VM `vps_firewall_sync` is deprecated.

1. Pick the target server

  • `.hostinger/vps.json` in the project: reuse its `virtual_machine_id`, `ipv4` and `domain` — without asking only when you or the user wrote it in an earlier deploy. If it came with a clone or download, name the server and confirm with the user first.
  • Otherwise `vps_virtual-machines_list` and let the user choose by `hostname` or IP. Keep `id`, `ipv4[0].address`, `ipv4[0].id` (for reverse DNS), `template.name`, `firewall_group_id` and `state`.
  • `state` other than `running`: hand over to `troubleshoot-vps`. `initial` means bought but not set up yet — `provision-vps`.

2. Get SSH access

Fresh templates log in as `root` with the root password set at setup; keys are optional. Skip this step when `ssh -o BatchMode=yes root@IP true` already succeeds.

1. Find or create a local key: `~/.ssh/id_ed25519.pub`, else `ssh-keygen -t ed25519 -N "" -f ~/.ssh/id_ed25519 -C hostinger-agent`. 2. `vps_ssh-keys_add-virtual-machine` with `keys: ["<contents of the .pub file>"]`. The key is written to `root`'s `authorized_keys` by the guest agent; check it with `vps_ssh-keys_list-virtual-machine`. 3. `ssh -o StrictHostKeyChecking=accept-new root@IP 'uname -a'`. If it is refused straight after adding the key, wait a minute and try again before changing anything else.

Still refused: port 22 closed from outside (`nc -zv -w 5 IP 22`) points at the firewall (step 3) or the guest OS; anything beyond that is `troubleshoot-vps`. Never store the private key in the project, and never print it.

3. Firewall

A Hostinger firewall group drops all inbound traffic that no accept rule matches, for IPv4 and IPv6, and needs at least one rule. Each VPS has at most one active group; a group can be shared by several servers. Rule changes reach new connections within about two minutes after a sync; open connections are kept.

1. `vps_firewall_list`; reuse a group whose rules match, else `vps_firewall_create` with a name like `web-<hostname>`. 2. `vps_firewall_create-rule` per port: `protocol: "SSH"` with `port: "22"`, `"HTTP"`/`"80"`, `"HTTPS"`/`"443"`, `source: "any"`, `source_detail: "any"`, plus the app's own ports only if they must be reached directly (prefer a reverse proxy on 80/443). Add the SSH rule before activating, or step 2 stops working. 3. `vps_firewall_activate` with the group and the server, then `vps_firewall_sync-to-all-assigned-v-ms` once it succeeds: a new group reads `is_synced: false` until synced, even though activation already applied its rules. Sync again after any later rule change. The sync answers `Request accepted`; `vps_firewall_get` shows `is_synced: true` when it is done. 4. Verify from outside: `nc -zv -w 5 IP 22` (on macOS a

Read more
@hostinger
Ships withapi-mcp-server

Model Context Protocol (MCP) server for Hostinger API.

Stars on GitHub

Momentum

stars in total
173
Star history of hostinger/api-mcp-server on GitHub, a chart by star-history.com

Other skills on api-mcp-server.

audit-hosting

audit-hosting

Audit a Hostinger web hosting account (Shared, Cloud and Agency plans) and report what needs attention: every plan and website,…

audit-vps

audit-vps

Audit every Hostinger VPS (KVM plans) on the account and report what needs attention: server state and failed actions, CPU,…

connect-domain

connect-domain

Connect a custom domain to a website on Hostinger web hosting (Shared, Cloud or Agency plans) end to end: attach the domain to…

headless

headless

Orchestrator for the Hostinger Headless build flow — build and deploy a real website on the user's Hostinger account from a…

connect

connect

Connect step for the Hostinger Headless flow, in two parts: get ready (verify Node, find or install the skill folder) before…

More skills from other plugins.

gitnexus-cli

gitnexus-cli

Use when the user needs to run GitNexus CLI commands like analyze/index a repo, check status, clean the index, generate a wiki,…

@abhigyanpatwari@abhigyanpatwariInstall Skill
fastmcp-client-cli

fastmcp-client-cli

Query and invoke tools on MCP servers using fastmcp list and fastmcp call. Use when you need to discover what tools a server…

fastmcp7d29k
@prefecthq@prefecthqInstall Skill
n8n-agents

n8n-agents

Design n8n AI agents the right way. Use when building or editing any @n8n/n8n-nodes-langchain.* AI node — an AI Agent, LLM chain,…

n8n-mcp7d23k
@czlonkowski@czlonkowskiInstall Skill
post-to-xhs

post-to-xhs

小红书内容发布技能。支持两种发布模式:(1) 上传图文模式 - 图片+短文;(2) 写长文模式 - 长篇文章+排版模板。 支持两种输入方式:用户提供完整内容和图片/图片URL,直接发布;或提供网页URL,自动提取内容和图片。…

@xpzouying@xpzouyingInstall Skill

Questions about deploy-to-vps.

Which coding agents can use deploy-to-vps?
deploy-to-vps installs in Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode and Windsurf with the skills CLI, using each agent's flag shown on this page. Flowy's auto-invocation, which fires a skill when your prompt matches, runs in Claude Code only.