Problems using GitHub external feed

I’m using the GitHub Repository Feed external feed type to pull in tags of the repository in order to execute the deployment scripts within, and am hitting a couple of problems.

Symbolic links are not restored in the local 'clone’

I’m unsure of how the repository is cloned in Octopus, whether it’s via an actual git clone, or through a download of the zip from GitHub releases, but the resulting clone fails to establish any symbolic links. I’ve tested both approaches locally (a fresh git clone and a download of the zip using wget / unzip) and symbolic links are successfully restored. Can you please offer some guidance on how to get this working. It would seem to be a bug given that the local clone does not reflect the source repository.

File Permissions are not restored

Similar to the first issue, in that the local clone does not reflect the source repository, I have to manually restore executable permissions on script files within the local clone for Octopus to run the scripts. For example, as a pre-deploy custom script, I have to run:

find . -name "*.sh" -exec chmod +x {} \;

Again, a local test of both a git clone and wget / unzip of the release zip successfully restore these permissions, so it looks like it’s down to how Octopus is handling the transfer of the repository.

Our environment consists of an Octopus Server (Windows host), and all tentacles are Linux machines. Could it be something to do with Windows being in the middle?

Your assistance would be greatly appreciated!

Update: I’ve tested setting the variable Octopus.Action.Package.DownloadOnTentacle=True, as documented here, to try to clone the repository directly on the tentacle (bypassing Windows) but this fails with the following error:

Downloading GitHub package xxx/yyy tagname from feed: 'https://api.github.com/'
Failed to download package xxx/yyy tagname from feed: 'https://api.github.com'
The remote server returned an error: (404) Not Found.

When I set Octopus.Action.Package.DownloadOnTentacle=True, the download works as expected (but with the same issues present as reported above).

Hi Steven,

Thanks for getting in touch! I am currently investigating the issues you are facing.

In regards to symbolic links and file permissions not being restored, it looks like that information is lost during the unzip process (Octopus downloads a zip of the repo rather then using git clone).

Unfortunately there is no easy fix as we are waiting on various updates to the underlying framework and library that Octopus uses.

I have linked the github issues of interest so you can keep an eye on progress.

Issues with symbolic links:


Issues with file permissions:

I will continue investigating to see if a solution can be found.

Cheers,
Ali

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.