Operation is not valid due to the current state of the object

Hello

we have octopus deploy server V 2021.2.7650

we are trying to integrate our private gitlab repository

this is our clone HTTPS URL https://gitlab.com/t4690/sandbox.git

we have added in github external feed as attached in screenshot

when we try search some file , we get error Operation is not valid due to the current state of the object.

Kindly help us on how to integrate private gitlab repo with octopus

Good morning @kakarlayogitha,

Thank you for contacting Octopus support and sorry you are having issues with connecting an external GitLab feed.

We do have some documentation on setting up a GitHub feed if you have not seen it yet that may help? GitLab works differently and we do not have any specific documentation on setting this kind of feed up.

A few things I have noticed from your screenshot that may be worth mentioning.

In our documentation for the GitHub feed you are supposed to set the URL to an API endpoint as described below:

So I think you would need to set that URL to https://gitlab.example.com/api/v4/ (this is what it suggests in their documentation) rather than your direct feed URL which is what I imagine you have put in that URL field.

Are you also using a Personal Access Token for your credentials? If not we recommend you set one up and use that, there is some documentation on Gitlab here for how to do this.

Hopefully implementing those changes helps but please let us know if it doesn’t.

Anything else you need in the meantime please feel free to reach out.

Kind Regards,

Clare Martin

Hi

Thanks for the update

This is the HTTPS Clone URL for my gitlab project

https://gitlab.com/yogithakakarla/firstgitlabproject.git

Please suggest me how to add an external feed to the same in octopus Please

Afternoon @kakarlayogitha,

Thank you for your patience with regards to waiting on a reply for this, we have done some testing and due to the API differences between GitHub and GitLab we can’t seem to get a GitLab external feed setup, no matter what endpoint we put into the External Feed URL Octopus throws an error as it’s expecting to interrogate a Github API, not GitLab.

We will do some more testing for you to see if we can get this to work, I will get back to you with our findings.

Anything else you need in the meantime please reach out!

Kind Regards,

Clare Martin

Good morning @kakarlayogitha,

Having spoken to our solutions team they have informed me that a GitLab feed cannot be set up as a GitHub external feed as you are attempting to do.

The reason we can’t use a GitHub Feed as a GitLab feed is that our external feed is designed to use API calls specific to GitHub.

Here is a list of supported package managers that GitLab support.

Can I ask what type of package you want to use and what is your end goal for setting this up? Are you wanting to push a package from Gitlab to Octopus so Octopus can then create releases for it?

I look forward to hearing your response so we can try help you further.

Kind Regards,

Clare Martin

Hello,

Can I ask what type of package you want to use and what is your end goal for setting this up? Are you wanting to push a package from Gitlab to Octopus so Octopus can then create releases for it?-> Yes , we want to push our code to gitlab and then deploy / create releases through Octopus

Please suggest

Morning @kakarlayogitha,

Thanks for answering those questions.

So, you would need to set up your package as a specific feed following the guides on GitLab (if you click on one of the supported feeds it tells you how to set that feed up in GitLab).

You would then set that feed up as an external feed within the Octopus UI.

The two easiest feeds to use are linked below (we recommend Nuget) but it does depend on your requirements and if your package supports those feed settings.

Maven Feed
NuGet Feed

I hope that helps, let me know if you have any further questions,

Kind Regards,

Clare Martin

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