Skip to content

Commit

Permalink
Add option to disable S3 server side encryption, fixes #312 (#313)
Browse files Browse the repository at this point in the history
Using the new env variable `WALG_DISABLE_S3_SSE` it should be possible to disable S3 SSE and it also does not change the existing behavior.
  • Loading branch information
bot-TeutoNet authored and CyberDem0n committed Feb 25, 2019
1 parent f5c4472 commit 4e4b8bf
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion postgres-appliance/scripts/configure_spilo.py
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,7 @@ def write_wale_environment(placeholders, prefix, overwrite):

wale = defaultdict(lambda: '')
for name in ['WALE_ENV_DIR', 'SCOPE', 'WAL_BUCKET_SCOPE_PREFIX', 'WAL_BUCKET_SCOPE_SUFFIX', 'WAL_S3_BUCKET',
'WAL_GCS_BUCKET', 'WAL_GS_BUCKET', 'WAL_SWIFT_BUCKET'] + s3_names + swift_names + gs_names:
'WAL_GCS_BUCKET', 'WAL_GS_BUCKET', 'WAL_SWIFT_BUCKET', 'WALG_DISABLE_S3_SSE'] + s3_names + swift_names + gs_names:
wale[name] = placeholders.get(prefix + name, '')

if wale['WAL_GS_BUCKET']: # WAL_GS_BUCKET is more consistent with WALE_GS_PREFIX
Expand Down Expand Up @@ -598,6 +598,8 @@ def write_wale_environment(placeholders, prefix, overwrite):
write_envdir_names.append('AWS_INSTANCE_PROFILE')
if wale.get('USE_WALG_BACKUP') and not wale.get('WALG_S3_SSE'):
wale['WALG_S3_SSE'] = 'AES256'
if wale.get('WALG_DISABLE_S3_SSE') == 'true' and 'WALG_S3_SSE' in wale:
del(wale['WALG_S3_SSE'])
elif wale.get('WAL_GCS_BUCKET'):
wale['WALE_GS_PREFIX'] = 'gs://{WAL_GCS_BUCKET}{BUCKET_PATH}'.format(**wale)
write_envdir_names = gs_names
Expand Down

0 comments on commit 4e4b8bf

Please sign in to comment.