Skip to content

Deployment Guide

This guide describes the current AIOHM production flow.

Branch Strategy

  • local-dev-* branches are the full development workspace
  • filtered-pr-* branches are GitHub-generated production snapshots
  • main is the clean production branch

You do not develop directly on main.

Release Flow

  1. Work locally on a local-dev-* branch.
  2. Push that branch to GitHub.
  3. GitHub builds VitePress from changeslog/ and prepares the filtered production PR.
  4. After merge, main builds a release ZIP with built frontend assets and built docs.
  5. The VPS deploy script downloads the latest release asset and updates the live platform.

What Ships To Production

  • application code under app/, config/, routes/, resources/, database/, and related runtime paths
  • install/ for first-time setup only
  • built documentation in public/docs/
  • built frontend assets in public/build/

What Does Not Ship To Production

  • raw VitePress source in changeslog/
  • dev helpers such as scripts/
  • tests
  • local dependency folders
  • runtime storage/ contents from a developer machine

First Install

Fresh installs use the installer package:

bash
bash install/bin/first-install.sh --production --yes

The installer handles setup tasks such as environment preparation, dependency install, migrations, seeding, storage linking, and initial cache warmup. After a successful first install, the install/ folder can be removed from the server.

Updating A Live VPS

From a full dev checkout, use the deployment helper:

bash
VPS_USE_SUDO=true bash scripts/github-aiohm-last-version.sh

That script downloads the latest GitHub release ZIP, preserves runtime state, updates application files, and runs the Laravel post-deploy steps on the VPS.

Runtime Paths To Preserve

  • .env
  • storage/
  • bootstrap/cache/ permissions
  • server-specific web and process manager configuration

Verification Checklist

  • https://aiohm.org returns 200
  • https://aiohm.org/docs/ returns 200
  • the expected release asset version is deployed
  • install/ is removed after first setup or upgrade finalization