terraform-provider-archive
terraform-provider-archive copied to clipboard
Support symlink
Hi!
This PR is as implementation of #6 Support for symlink file/dir archive and Excludes option. All symlink files will be resolves and included in the archive file.
Is there any chance this could be merged in? It would solve an annoying problem we have
This branch was out-of-date to master for a few months, so I rebased onto master and rebuilt this PR.
And since Travis' symlink feature wasn't enabled in the Windows environment, I modified the travis.yml and passed all the tests.
@wilkmaia Is it possible that this PR will be merged?
Hi, sorry to hassle maintainers, but this feels like its ready (or extremely close to it) for merge, and @moajo has done their best to keep it up to date with master/main. its not a huge bug, but it is a really awkward problem to work around and while a fix is present it seems a shame not to get it merged.
Is there anything anyone can do to get this prioritised for a merge?
I actually came across this because i have had a lot of issues with archive_file zip files creating oddly malformed symlinks. I was going to take a stab at fixing the issue, but given my major lack of Go knowledge I was really happy to find that someone better at this than me had already solved the problem!
It would really great to get this bug squashed :)
I would also note that @wilkmaia already approved the PR, so i'm guessing it must be pretty much ready to go?
@moajo A question about your PR.
For AWS lambda I am using virtualenv within docker container (using the official lambda image) that creates some symlinks in /venv/path/bin .
Outside the container these links looks like they are broken.
ls -la layers/packages/ansible/bin/python
lrwxrwxrwx 1 root root 23 Dez 3 07:56 layers/packages/ansible/bin/python -> /var/lang/bin/python3.8
Does your implementation covers archiving these kind of symlinks?
@moajo as the archive provider has now been migrated from SDKv2 to the Terraform Plugin Framework, I have incorporated your changes from this PR into #183 and added you as a coauthor as the vast majority of the changes are in this PR. The only significant change I made in #183 was the handling of symbolic links that are using an absolute path. If you would rather rebase this PR on the latest main then please go ahead and I will close out #183. Thank you very much for your contribution.
Implemented in #183 and released in v2.4.0.
I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions. If you have found a problem that seems related to this change, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.