edmunds/shadowreader

Running in to error trying to playback parsed logs

lkamenkovich opened this issue · 5 comments

Hello, I have followed the instructions to parse logs from the local file and it successfully parsed the logs to local-parsed-logs S3 bucket. Now when I want to send the traffic from parsed logs I run in to this error: An error occurred: SrDataBucketS3Bucket - local-parsed-logs already exists. How I can run Shadowrunner so it does not do the parse, since it was already done from the local file and just do the playback part? Thank you very much.

Hi @lkamenkovich, thanks for reporting this.
Can you post here the contents of your shadowreader.yml and serverless.yml files? I suspect what is happening is that Serverless is trying (and failing) to create a local-parsed-logs bucket because that is what parsed_data_bucket is set to in serverless.yml.
Most likely if you set parsed_data_bucket to something else, it should deploy.

I don't think the files were attached successfully. Could you try it again?

Here are the yml files in text format, could not attach .yml files. So if I set parsed_data_bucket to the local-parsed-log (where the parsed local logs are stored from previous run of local parser.py) it gives me the error: SrDataBucketS3Bucket - local-parsed-logs already exists.
If I set it to something else, it creates an empty parsed folder and no traffic is played back. Thank you, Larissa
serverless-yml.txt
Shadoreader-yml.txt

Thanks for posting the configs. Can you try this? Set parsed_data_bucket to local-parsed-log then comment out this whole section in serverless.yml:

  SrDataBucketS3Bucket:
    Type: AWS::S3::Bucket
    Properties:
      BucketName: ${self:custom.parsed_data_bucket}
      Tags:
        -
          Key: "Name"
          Value: "shadowreader"

      LifecycleConfiguration:
        Rules:
        - Id: ExpireDatain30Days
          Prefix: ''
          Status: Enabled
          ExpirationInDays: '30'

This will prevent Serverless from trying to deploy a bucket with the same name.