* Modules, themes, and extensions * Publisher profiles and verification metadata * Installed-package tracking * Semantic version compatibility checks * PHP, Laravel, and Content Manager compatibility checks * Dependency resolution * SHA-256 checksum validation * Package signature requirements * Installation and update history * Enable and disable controls * Removal handling * Rollback records * Licence records * Marketplace administration UI * Authenticated REST endpoints * Console audit and synchronisation commands * Permissions and sidebar integration * Feature tests
31 lines
1.4 KiB
PHP
31 lines
1.4 KiB
PHP
<?php
|
|
namespace Modules\Marketplace\Providers;
|
|
use Illuminate\Support\ServiceProvider;
|
|
use Modules\Marketplace\Services\CompatibilityChecker;
|
|
use Modules\Marketplace\Services\DependencyResolver;
|
|
use Modules\Marketplace\Services\MarketplaceManager;
|
|
use Modules\Marketplace\Services\PackageManifest;
|
|
use Modules\Marketplace\Services\PackageVerifier;
|
|
final class MarketplaceServiceProvider extends ServiceProvider
|
|
{
|
|
public function register(): void
|
|
{
|
|
$this->mergeConfigFrom(module_path('Marketplace', 'Config/config.php'), 'marketplace');
|
|
$this->app->singleton(PackageManifest::class);
|
|
$this->app->singleton(CompatibilityChecker::class);
|
|
$this->app->singleton(DependencyResolver::class);
|
|
$this->app->singleton(PackageVerifier::class);
|
|
$this->app->singleton(MarketplaceManager::class);
|
|
$this->app->register(RouteServiceProvider::class);
|
|
}
|
|
public function boot(): void
|
|
{
|
|
$this->loadMigrationsFrom(module_path('Marketplace', 'Database/Migrations'));
|
|
$this->loadViewsFrom(module_path('Marketplace', 'Resources/views'), 'marketplace');
|
|
$this->loadTranslationsFrom(module_path('Marketplace', 'Resources/lang'), 'marketplace');
|
|
if ($this->app->runningInConsole()) {
|
|
$this->commands([\Modules\Marketplace\Console\Commands\MarketplaceSyncCommand::class, \Modules\Marketplace\Console\Commands\MarketplaceAuditCommand::class]);
|
|
}
|
|
}
|
|
}
|