Skip to content

Commit

Permalink
Merge pull request #202 from sunilk747/update-bucket
Browse files Browse the repository at this point in the history
update bukcet name
  • Loading branch information
Sunil Kumar authored Jul 23, 2019
2 parents d4830f5 + cdd528c commit a23d978
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
13 changes: 8 additions & 5 deletions openshift/template.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,13 +78,13 @@ objects:
- name: AWS_S3_ACCESS_KEY_ID
valueFrom:
secretKeyRef:
name: aws
key: s3-access-key-id
name: developer-analytics-audit-report-s3
key: aws_access_key_id
- name: AWS_S3_SECRET_ACCESS_KEY
valueFrom:
secretKeyRef:
name: aws
key: s3-secret-access-key
name: developer-analytics-audit-report-s3
key: aws_secret_access_key
- name: THREESCALE_ACCOUNT_SECRET
valueFrom:
secretKeyRef:
Expand All @@ -99,7 +99,10 @@ objects:
- name: CLASS_TYPE
value: "sync"
- name: REPORT_BUCKET_NAME
value: developer-analytics-audit-report
valueFrom:
secretKeyRef:
name: developer-analytics-audit-report-s3
key: bucket
- name: DEPLOYMENT_PREFIX
valueFrom:
configMapKeyRef:
Expand Down
2 changes: 1 addition & 1 deletion src/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ def __init__(self):

def list_objects(self, frequency='weekly'):
"""Fetch the list of objects found on the S3 bucket."""
prefix = '{dp}/{freq}'.format(dp=self.deployment_prefix, freq=frequency)
prefix = '{freq}'.format(freq=frequency)
res = {'objects': []}
for obj in self.s3_bucket_obj.objects.filter(Prefix=prefix):
if os.path.basename(obj.key) != '':
Expand Down

0 comments on commit a23d978

Please sign in to comment.