feat: add S3-compatible storage provider (MinIO, Ceph, R2, etc.)

Adds a new 'S3-Compatible Storage' provider that works with any
S3-API-compatible object storage service, including MinIO, Ceph,
Cloudflare R2, Backblaze B2, and others.

Changes:
- New provider class: classes/providers/storage/s3-compatible-provider.php
  - Provider key: s3compatible
  - Reads user-configured endpoint URL from settings
  - Uses path-style URL access (required by most S3-compatible services)
  - Supports credentials via AS3CF_S3COMPAT_ACCESS_KEY_ID /
    AS3CF_S3COMPAT_SECRET_ACCESS_KEY wp-config.php constants
  - Disables AWS-specific features (Block Public Access, Object Ownership)
- New provider SVG icons (s3compatible.svg, -link.svg, -round.svg)
- Registered provider in main plugin class with endpoint setting support
- Updated StorageProviderSubPage to show endpoint URL input for S3-compatible
- Built pro settings bundle with rollup (Svelte 4.2.19)
- Added package.json and updated rollup.config.mjs for pro-only builds
This commit is contained in:
2026-03-03 12:30:18 +01:00
commit 3248cbb029
2086 changed files with 359427 additions and 0 deletions

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -0,0 +1,6 @@
<?php
namespace DeliciousBrains\WP_Offload_Media\Aws3;
// This file was auto-generated from sdk-root/src/data/cloudfront/2015-07-27/endpoint-tests-1.json
return ['testCases' => [['documentation' => 'For region aws-cn-global with FIPS disabled and DualStack disabled', 'expect' => ['endpoint' => ['properties' => ['authSchemes' => [['name' => 'sigv4', 'signingName' => 'cloudfront', 'signingRegion' => 'cn-northwest-1']]], 'url' => 'https://cloudfront.cn-northwest-1.amazonaws.com.cn']], 'params' => ['Region' => 'aws-cn-global', 'UseDualStack' => \false, 'UseFIPS' => \false]], ['documentation' => 'For region aws-global with FIPS disabled and DualStack disabled', 'expect' => ['endpoint' => ['properties' => ['authSchemes' => [['name' => 'sigv4', 'signingName' => 'cloudfront', 'signingRegion' => 'us-east-1']]], 'url' => 'https://cloudfront.amazonaws.com']], 'params' => ['Region' => 'aws-global', 'UseDualStack' => \false, 'UseFIPS' => \false]], ['documentation' => 'For custom endpoint with fips disabled and dualstack disabled', 'expect' => ['endpoint' => ['url' => 'https://example.com']], 'params' => ['Region' => 'us-east-1', 'UseDualStack' => \false, 'UseFIPS' => \false, 'Endpoint' => 'https://example.com']], ['documentation' => 'For custom endpoint with fips enabled and dualstack disabled', 'expect' => ['error' => 'Invalid Configuration: FIPS and custom endpoint are not supported'], 'params' => ['Region' => 'us-east-1', 'UseDualStack' => \false, 'UseFIPS' => \true, 'Endpoint' => 'https://example.com']], ['documentation' => 'For custom endpoint with fips disabled and dualstack enabled', 'expect' => ['error' => 'Invalid Configuration: Dualstack and custom endpoint are not supported'], 'params' => ['Region' => 'us-east-1', 'UseDualStack' => \true, 'UseFIPS' => \false, 'Endpoint' => 'https://example.com']]], 'version' => '1.0'];

View File

@@ -0,0 +1,6 @@
<?php
namespace DeliciousBrains\WP_Offload_Media\Aws3;
// This file was auto-generated from sdk-root/src/data/cloudfront/2015-07-27/paginators-1.json
return ['pagination' => ['ListCloudFrontOriginAccessIdentities' => ['input_token' => 'Marker', 'limit_key' => 'MaxItems', 'more_results' => 'CloudFrontOriginAccessIdentityList.IsTruncated', 'output_token' => 'CloudFrontOriginAccessIdentityList.NextMarker', 'result_key' => 'CloudFrontOriginAccessIdentityList.Items'], 'ListDistributions' => ['input_token' => 'Marker', 'limit_key' => 'MaxItems', 'more_results' => 'DistributionList.IsTruncated', 'output_token' => 'DistributionList.NextMarker', 'result_key' => 'DistributionList.Items'], 'ListInvalidations' => ['input_token' => 'Marker', 'limit_key' => 'MaxItems', 'more_results' => 'InvalidationList.IsTruncated', 'output_token' => 'InvalidationList.NextMarker', 'result_key' => 'InvalidationList.Items'], 'ListStreamingDistributions' => ['input_token' => 'Marker', 'limit_key' => 'MaxItems', 'more_results' => 'StreamingDistributionList.IsTruncated', 'output_token' => 'StreamingDistributionList.NextMarker', 'result_key' => 'StreamingDistributionList.Items']]];

View File

@@ -0,0 +1,6 @@
<?php
namespace DeliciousBrains\WP_Offload_Media\Aws3;
// This file was auto-generated from sdk-root/src/data/cloudfront/2015-07-27/waiters-2.json
return ['version' => 2, 'waiters' => ['DistributionDeployed' => ['acceptors' => [['argument' => 'Distribution.Status', 'expected' => 'Deployed', 'matcher' => 'path', 'state' => 'success']], 'delay' => 60, 'description' => 'Wait until a distribution is deployed.', 'maxAttempts' => 25, 'operation' => 'GetDistribution'], 'InvalidationCompleted' => ['acceptors' => [['argument' => 'Invalidation.Status', 'expected' => 'Completed', 'matcher' => 'path', 'state' => 'success']], 'delay' => 20, 'description' => 'Wait until an invalidation has completed.', 'maxAttempts' => 30, 'operation' => 'GetInvalidation'], 'StreamingDistributionDeployed' => ['acceptors' => [['argument' => 'StreamingDistribution.Status', 'expected' => 'Deployed', 'matcher' => 'path', 'state' => 'success']], 'delay' => 60, 'description' => 'Wait until a streaming distribution is deployed.', 'maxAttempts' => 25, 'operation' => 'GetStreamingDistribution']]];