-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
archive_file produces a corrupted zip file #282
Comments
Hi @AbirHamzi 👋 Sorry you ran into trouble here. Can you provide some further details on the discrepancy between the archive generated by using archive_file versus the archive produced by running the zip command directly? Specifically, which files are being excluded from the archive when archive_file is used compared to using the zip command? |
I am seeing the same issue |
hi, I am facing the same issue with this module, this is happening in aws code pipeline when I am trying to deploy a lambda function compressing the code.
Error during the apply
I tried to replicate this locally and I did it once, after that the module have been working as expected. As @AbirHamzi mentioned, the size of the generated file is smaller than the expected and it's not possible to open the file. |
I'm closing this issue because my problem has been resolved. Even though the number of files compressed with 'archive_file' is not the same as those compressed with the 'zip' command, it was not the reason why my file is corrupted |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Terraform CLI and Provider Versions
Terraform v1.6.5
Provider v2.4.0
Terraform Configuration
Expected Behavior
I expect to see the same number of compressed files as the CLI zip command and I can run the unzip command without problems.
Actual Behavior
my-code.zip: compressed by archive_file
my-code1.zip: compressed by the zip command
$ zipinfo my-code.zip
2184 files, 21307869 bytes uncompressed, 13355944 bytes compressed: 37.3%
$ zipinfo my-code1.zip
3057 files, 21307869 bytes uncompressed, 13302202 bytes compressed: 37.6%
Steps to Reproduce
terraform apply
How much impact is this issue causing?
High
Logs
No response
Additional Information
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: