Optum / dce-cli

Disposable Cloud Environment CLI
Apache License 2.0
38 stars 20 forks source link

Error after running `dce system deploy` second time #70

Open nathanagood opened 4 years ago

nathanagood commented 4 years ago

Version information

Describe the bug

I can run dce system deploy fine once, but after destroying the infra when I run the command again I get the following error:

reading file in zip archive: file already exists: <HOME>/.dce/.cache/dce/0.23.0/lambda/accounts.zip

To Reproduce

Steps to reproduce the behavior:

  1. When I type this Command, I get the following output

    $ dce system deploy
  2. Then when I type this other command, I get the following error

    $ cd ~/.dce/.cache/module/
    $ ../terraform/<version>/terraform destroy -auto-approve -no-color
    $ dce system deploy
    'main.tf' already exists and --use-cached specified; using existing file
    Initializing
    Creating DCE infrastructure
    Retrieving artifacts location
    Artifacts bucket =  <some bucket>
    Deploying code assets to DCE infrastructure
    Downloading DCE code assets
    reading file in zip archive: file already exists: ~/.dce/.cache/dce/0.23.0/lambda/accounts.zip

Expected behavior

Additional context

Workaround: remove the ~/.dce/.cache directory