page:recipes:appointment booking:laravel:relational workflow

Host appointment booking with Laravel: relational workflow state

Deploy a appointment booking built with Laravel on Ample using the transactional workflows pattern. Compute runs the app in an isolated microVM behind a public HTTPS URL, a managed PostgreSQL 16 database is auto-provisioned and injected as DATABASE_URL. Verified on Laravel: an optimistic version check and an event row written in the same transaction, a stale update rejected, and a history query over the application-owned events (history=2 conflict=rejected). Not separately tested: your domain records, validation rules and concurrency policy; treat the appointment booking-specific behavior as your application code.

Summary

Representative Queries

  1. Host appointment booking with Laravel: relational workflow state
  2. Where can I host Appointment booking built with Laravel?
  3. I need a domain record schema, validation rules and concurrency behavior.

Resource Requirements

Workflow Steps

  1. Build and start
    • composer install --no-dev from composer.lock, then FrankenPHP serving public/ (php-server with the index.php fallback) reading PORT on the php-8.5 template. The server must bind 0.0.0.0 on PORT.
  2. Implement the pattern on PostgreSQL
    • The fixture's module implements transactional workflows: an optimistic version check and an event row written in the same transaction, a stale update rejected, and a history query over the application-owned events (history=2 conflict=rejected). Copy the approach into your schema; keep migrations idempotent and run them with --release-command.
  3. Deploy
    • ample deploy . --name --public
  4. Verify
    • ample logs --kind build then --kind runtime

Limitations

Success Checks

  1. App responds on its public URL:
    • Kind: http_get
    • Path: /
    • Expect: ample canary laravel patterns
  2. Transactional-workflows self-test:
    • Kind: http_get
    • Path: /p/transactional-workflows
    • Expect: tx=ok history=2 conflict=rejected

Cost Estimate

Input Schema

{
  "additionalProperties": false,
  "properties": {
    "env": {
      "description": "Encrypted environment variables (bucket credentials, secrets)",
      "items": {
        "pattern": "^[A-Z][A-Z0-9_]*=.*$",
        "type": "string"
      },
      "maxItems": 50,
      "type": "array"
    },
    "name": {
      "description": "App name",
      "maxLength": 63,
      "minLength": 1,
      "pattern": "^[a-z0-9-]+$",
      "type": "string"
    },
    "path": {
      "description": "Project directory or ample.toml service",
      "maxLength": 512,
      "minLength": 1,
      "type": "string"
    },
    "release_command": {
      "description": "Migration command run before activation",
      "maxLength": 512,
      "type": "string"
    }
  },
  "required": ["name", "path"],
  "type": "object"
}

Examples