Skip to content

Configuration

Phillip Dornauer edited this page Apr 13, 2026 · 3 revisions

Configuration

Marble is configured in config/marble.php. Publish it with:

docker compose exec app php artisan vendor:publish --tag=marble-config

Many settings can also be changed at runtime via Dashboard → Configuration in the admin without editing the config file.

All Options

route_prefix

  • Type: string
  • Default: 'admin'
  • Description: URL prefix for the admin panel. Change to move admin to a different path (e.g. 'cms'/cms/).

guard

  • Type: string
  • Default: 'marble'
  • Description: Laravel auth guard used for admin authentication. Usually no need to change.

primary_locale

  • Type: string
  • Default: 'en'
  • Description: The primary language code. Non-translatable fields are always stored under this locale.

locale

  • Type: string
  • Default: 'en'
  • Description: The current locale used when none is passed explicitly to facade methods.

uri_locale_prefix

  • Type: boolean
  • Default: false
  • Description: When true, all frontend URLs are prefixed with the language code (e.g. /en/about, /de/ueber-uns). When false, all language slugs share the same URL space — Marble detects the language from the slug.

entry_item_id

  • Type: int
  • Default: 1
  • Description: The root item of the content tree. Fallback for user groups that don't have their own entry item configured.

frontend_url

  • Type: string
  • Default: ''
  • Description: Base URL prepended when generating frontend URLs in the admin (preview links, "Reachable via" links). Set via MARBLE_FRONTEND_URL in .env.

auto_routing

  • Type: boolean
  • Default: false
  • Description: When true, Marble registers a catch-all frontend route automatically — no routes/web.php entry needed. Set to false if you have custom routes (search, portal login, etc.) that must be registered before the catch-all.

cache_ttl

  • Type: int
  • Default: 3600 (seconds)
  • Description: How long items are cached. Set to 0 to disable caching entirely (useful during development).

storage_disk

  • Type: string
  • Default: 'public'
  • Description: Laravel filesystem disk for media uploads. Change to 's3' or another disk for cloud storage.

autosave

  • Type: boolean
  • Default: false
  • Description: Enable auto-save in the item editor.

autosave_interval

  • Type: int
  • Default: 30 (seconds)
  • Description: How often the editor auto-saves.

lock_ttl

  • Type: int
  • Default: 300 (seconds)
  • Description: How long a content lock lasts before expiring.

portal_registration

  • Type: boolean
  • Default: false
  • Description: Enable self-registration for portal users at /portal/register.

portal_home

  • Type: string
  • Default: '/'
  • Description: URL portal users are redirected to after login.

Example Config

return [
    'route_prefix'        => 'admin',
    'guard'               => 'marble',
    'primary_locale'      => 'en',
    'locale'              => 'en',
    'uri_locale_prefix'   => false,
    'entry_item_id'       => 1,
    'frontend_url'        => env('MARBLE_FRONTEND_URL', ''),
    'auto_routing'        => env('MARBLE_AUTO_ROUTING', false),
    'cache_ttl'           => 3600,
    'storage_disk'        => 'public',
    'autosave'            => false,
    'autosave_interval'   => 30,
    'lock_ttl'            => 300,
    'portal_registration' => false,
    'portal_home'         => '/',
];

Scheduled Publishing

To automatically publish and expire items based on their scheduled dates, add this to your Laravel scheduler in routes/console.php:

Schedule::command('marble:schedule-publish')->everyMinute();

Recommended Scheduler

Schedule::command('marble:schedule-publish')->everyMinute();
Schedule::command('marble:workflow-deadlines')->daily();
Schedule::command('marble:prune')->weekly();

Clone this wiki locally