web/website/integrations/mybb/provision-system-boards.php

10 lines
522 B
PHP

<?php
// CLI publication and authenticated first-open repair share the same provisioner.
if (PHP_SAPI !== 'cli') { http_response_code(404); exit; }
$input=json_decode(stream_get_contents(STDIN),true,512,JSON_THROW_ON_ERROR);
define('IN_MYBB',1);
if(!defined('NO_PLUGINS'))define('NO_PLUGINS',1);
define('MYBB_ROOT','/home/dunerealms/apps/integrations/mybb/');
require MYBB_ROOT.'inc/init.php';
require __DIR__.'/system-board-provision.php';
echo json_encode(dune_provision_system_boards($input),JSON_THROW_ON_ERROR)."\n";