A partire BackWPup 3.6.10 BackWPup , è possibile aggiungere nuovi servizi S3 all'elenco predefinito tramite il filtro hook backwpup_s3_destination devono essere aggiunti.
Ogni servizio che vogliamo aggiungere può essere specificato tramite un array che indica il nome, la regione e l'URL del servizio che desideriamo aggiungere.
Ecco un esempio:
add_filter( 'backwpup_s3_destination', function ( $destinations ) {
return array_merge( array(array(
'label' => __( 'FirstServiceTest: AMS3', 'backwpup' ),
'region' => 'ams3',
'base_url' => 'https://example.com',
),
array(
'label' => __( 'SecondServiceTest: AMS', 'backwpup' ),
'region' => 'nl-ams',
'base_url' => 'https://example.com',
)
), $destinations );
} );
In questo esempio definiamo due array, uno per FirstServiceTest e uno per SecondServiceTest.
Questi nuovi servizi sono ora disponibili nell'elenco dei servizi S3 per i relativi lavori.