Skip to content

Laravel

A Laravel application runs on SKE through the bridge, the Composer package ske-io/laravel-bridge. It connects the application’s HTTP requests, queued jobs, commands and scheduler to the platform.

The bridge supports PHP 8.3 or later and Laravel 11, 12 and 13. From the application’s root:

Terminal window
composer require ske-io/laravel-bridge

Laravel discovers the service provider, so there is nothing to register or configure. Off the platform the bridge stays inactive, apart from the upload endpoint, so the same application runs locally as before.

On AWS, the platform’s queue connection sends jobs to SQS through the AWS SDK, which the bridge doesn’t require. Install it if the application doesn’t have it yet:

Terminal window
composer require aws/aws-sdk-php
  • Queues: adds the ske queue connection (SQS on AWS, Cloud Tasks on GCP) and runs the jobs the platform delivers, recording failures in the application’s failed jobs store. See Queues.
  • Logs: writes logs to stderr, one JSON line per record, so the logs show level, message, context and exception.
  • Proxies: trusts the platform’s load balancer, so the request’s scheme, host and client address are the real ones.
  • AWS credentials: lets the AWS SDK use the function role’s temporary credentials. A key pair the application sets itself still wins.
  • Mail: sends SES mail from the region of the mail provider linked to the environment.
  • Maintenance mode: follows the maintenance mode set in the dashboard. See Maintenance mode.
  • Encrypted environment file: loads the environment’s .env.{environment}.encrypted when its key is set. See Encrypted environment file.
  • Inertia SSR: when SSR is turned on for the environment, sends Inertia’s render calls to the platform’s SSR server. This needs inertiajs/inertia-laravel.