Skip to content

Commit 00c80a6

Browse files
authored
Merge pull request cloudfoundry#139 from zrob/kms-docs
document aws kms encryption configuration
2 parents e8406a9 + 59c203e commit 00c80a6

File tree

1 file changed

+42
-2
lines changed

1 file changed

+42
-2
lines changed

common/cc-blobstore-config.html.md.erb

+42-2
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,9 @@ To use Fog blobstores with AWS credentials, perform the following steps:
5252

5353
##<a id="fog-aws-sse"></a> Fog with AWS Server-Side Encryption
5454

55-
AWS S3 offers Server-Side Encryption at rest. For more information, see <a href="http://docs.aws.amazon.com/AmazonS3/latest/dev/UsingServerSideEncryption.html">Protecting Data Using Server-Side Encryption with Amazon S3-Managed Encryption Keys (SSE-S3)</a>.
55+
AWS S3 offers Server-Side Encryption at rest. For more information, see <a href="http://docs.aws.amazon.com/AmazonS3/latest/dev/serv-side-encryption.html">Protecting Data Using Server-Side Encryption</a>.
5656

57-
To use Fog blobstores with AWS SSE-S3 encryption, perform the following steps:
57+
<strong>AWS SSE-S3 blobstore encryption</strong>
5858

5959
1. Insert the following configuration into your manifest under `properties.cc`:
6060

@@ -91,6 +91,46 @@ To use Fog blobstores with AWS SSE-S3 encryption, perform the following steps:
9191

9292
1. `fog_aws_storage_options` takes a hash with the key `encryption`. Operators can set its value to a type of encryption algorithm. In the configuration information above, `encryption` is set to `AES256` in order to enable AWS SSE-S3 encryption. Further configuration can be provided through the `fog_aws_storage_options` hash, which is passed through to the Fog gem.
9393

94+
<strong>AWS SSE-KMS blobstore encryption</strong>
95+
96+
1. Get your KMS Key ID. For information on managing KMS keys, see <a href='http://docs.aws.amazon.com/kms/latest/developerguide/getting-started.html'>the getting started guide.</a>
97+
98+
1. Insert the following configuration into your manifest under `properties.cc`:
99+
100+
```
101+
cc:
102+
buildpacks:
103+
blobstore_type: fog
104+
buildpack_directory_key: YOUR-AWS-BUILDPACK-BUCKET
105+
fog_connection: &fog_connection
106+
aws_access_key_id: AWS_ACCESS_KEY
107+
aws_secret_access_key: AWS_SECRET_ACCESS_KEY
108+
provider: AWS
109+
region: us-east-1
110+
fog_aws_storage_options: &fog_aws_storage_options
111+
encryption: 'aws:kms'
112+
x-amz-server-side-encryption-aws-kms-key-id: "YOUR-AWS-KMS-KEY-ID"
113+
droplets:
114+
blobstore_type: fog
115+
droplet_directory_key: YOUR-AWS-DROPLET-BUCKET
116+
fog_connection: *fog_connection
117+
fog_aws_storage_options: *fog_aws_storage_options
118+
packages:
119+
blobstore_type: fog
120+
app_package_directory_key: YOUR-AWS-PACKAGE-BUCKET
121+
fog_connection: *fog_connection
122+
fog_aws_storage_options: *fog_aws_storage_options
123+
resource_pool:
124+
blobstore_type: fog
125+
resource_directory_key: YOUR-AWS-RESOURCE-BUCKET
126+
fog_connection: *fog_connection
127+
fog_aws_storage_options: *fog_aws_storage_options
128+
```
129+
130+
1. Replace `AWS_ACCESS_KEY` and `AWS_SECRET_ACCESS_KEY` with your AWS credentials. Replace `YOUR-AWS-BUILDPACK-BUCKET`, `YOUR-AWS-DROPLET-BUCKET`, `YOUR-AWS-PACKAGE-BUCKET`, `YOUR-AWS-RESOURCE-BUCKET` with the names of your AWS buckets. Replace `YOUR-AWS-KMS-KEY-ID` with your KMS Key ID. Do not use periods (`.`) in your AWS bucket names. In the AWS console, you must assign your credentials an IAM policy that allows all S3 actions on all of these buckets. Further configuration can be provided through the <code>fog_connection</code> hash, which is passed through to the Fog gem.
131+
132+
1. `fog_aws_storage_options` takes a hash with the key `encryption`. Operators can set its value to a type of encryption algorithm. In the configuration information above, `encryption` is set to `aws:kms` in order to enable AWS SSE-KMS encryption. Further configuration can be provided through the `fog_aws_storage_options` hash, which is passed through to the Fog gem.
133+
94134
##<a id="fog-aws-iam"></a> Fog with AWS IAM Instance Profiles
95135

96136
To configure Fog blobstores to use <a href="http://docs.aws.amazon.com/IAM/latest/UserGuide/id_roles_use_switch-role-ec2.html">AWS IAM Instance Profiles</a>, perform the following steps:

0 commit comments

Comments
 (0)