public function StreamWrapperConfiguration::setCloudFrontCredentials in AmazonS3 7.2
Set the CloudFront credentials to use.
Parameters
string $path: The path to the file containing the private key.
string $keyPairId: The key pair ID.
File
- src/
StreamWrapperConfiguration.php, line 259
Class
- StreamWrapperConfiguration
- Class to manage S3 stream wrapper configuration.
Namespace
Drupal\amazons3Code
public function setCloudFrontCredentials($path, $keyPairId) {
if (!file_exists($path)) {
throw new \InvalidArgumentException("{$path} does not exist.");
}
$this->data['cloudFrontPrivateKey'] = $path;
$this->data['cloudFrontKeyPairId'] = $keyPairId;
}