aral-vps-test CLI
aral-vps-test is an oclif-powered command-line interface (CLI) tool designed for managing virtual private server (VPS) environments, particularly for creating, listing, starting, and updating workspaces. It provides commands for system-level operations like `init`, `start`, and `destroyAll`, as well as specific workspace management functions such as `workspace:create` and `workspace:list`. The package is currently at version 1.0.34 and primarily serves as a utility for developers and system administrators to automate VPS provisioning and deployment tasks. It is built with TypeScript, offering type declarations, and its release cadence follows a typical npm package update cycle as needed for feature enhancements or bug fixes. Its key differentiator is simplifying the lifecycle management of multiple repository branches as 'workspaces' on a VPS.
Common errors
-
aral: command not found
cause The `aral-vps-test` package was not installed globally, or the global npm bin directory is not in your system's PATH.fixRun `npm install -g aral-vps-test` to install the CLI globally. If the issue persists, ensure your shell's PATH includes the directory where global npm binaries are installed (e.g., `$(npm root -g)/../.bin`). -
Error: EACCES: permission denied, access 'config-file-path'
cause The CLI is attempting to write to or read from a configuration file without sufficient file system permissions.fixEnsure the user running the `aral` command has appropriate read/write permissions for the configuration directory and files. You may need to use `sudo` for initial setup or adjust directory permissions (e.g., `sudo chown -R $(whoami) /usr/local/lib/node_modules` for global installs if permissions are wrong, though this needs caution). -
Configuration file not found. Please run `aral init` first.
cause Many `aral` commands depend on an initial configuration, which is set up via the `init` command.fixExecute `aral init` to go through the interactive configuration wizard and set up the necessary environment files before running other commands.
Warnings
- gotcha The `aral destroyAll` command performs a destructive action, removing all system containers. It explicitly states that after execution, `authorized_keys` for the Webhook container will need to be re-set.
- gotcha As an oclif CLI, this tool relies on Node.js being installed and accessible in the system's PATH. Ensure your Node.js version meets the `engines` requirement ( `>=8.0.0` ) for stable operation.
Install
-
npm install aral-vps-test -
yarn add aral-vps-test -
pnpm add aral-vps-test
Imports
- DestroyAll
const DestroyAll = require('aral-vps-test/lib/commands/destroyAll');import DestroyAll from 'aral-vps-test/lib/commands/destroyAll';
- Init
const Init = require('aral-vps-test/lib/commands/init');import Init from 'aral-vps-test/lib/commands/init';
- WorkspaceCreate
const WorkspaceCreate = require('aral-vps-test/lib/commands/workspace/create');import WorkspaceCreate from 'aral-vps-test/lib/commands/workspace/create';
Quickstart
npm install -g aral-vps-test aral init # Follow the interactive configuration wizard. aral start # Starts the system based on your configuration. aral workspace:create my-repo main github # Creates a workspace for 'my-repo' from the 'main' branch on GitHub.