david-www
david-www copied to clipboard
Add support to gitlab
I think, it's really helpfull to add support for gitlab server. Since the gitlabs servers are 'private', that is possible by launching David on our servers
I too would find support for GitLab to be beneficial. I've found david-dm.org to be a great resource for determining the health of a project, and a way to ensure my own projects are kept updated in a timely manner.
However, with many of my repositories stored on a private GitLab server, the use of david-dm.org is impossible. Therefore it would be nice if david-www could be launched within the same private confines as the GitLab server I use, while providing the same usefulness already afforded by david-dm.org
@alanshaw for developers that wish to contribute one or more PR towards this request what would be the roadmap we should follow to build in GitLab support into david-www
.
Hi @throrin19 @hbetts
We've had a PR to implement this before so in theory it should already be possible. I have no access to a gitlab so can't test myself. The site should be configurable enough for you to run it and point it at a gitlab so really it's up to you to try it out and send a PR for things that don't work!
Anything you can contribute towards making this possible is much appreciated!
@alanshaw This PR is about Github enterprise, not Gitlab.
It would be great if gitlab api would be chooseable. I will lookup if I can free some time to do it myself.
Thank you @wzrdtales!
It would be really nice to see support for GitLab in the same way GitHub Enterprise is supported.
I'm not sure the extent of refactoring that will be required to support GitLab in david-www
. That's one reason I haven't dived into it myself. @wzrdtales if you have an opportunity to work on this enhancement request, please let me know, and I can see if I can test it out.
Hi, I just started working on this https://github.com/wzrdtales/david-www/commit/965a61b1d903beeb56f76243daafafc448127b8e
There is a lot to redesign, I will do this by writing an abstraction for the gitlab interface to fit the github interface.
This commit is already enough to access the repository, replacing in manifest.js the ./github require with ./gitlab
I will try to get this thing on the weekend done and integrated, to use both gitlab and github at the same time.
@destroyerofbuilds Ok, it's in there, currently the gitlab package doesn't cover all functionality. So i stop here for now.
The gitlab repos are accessable over /r/gitlab/:user/...
Basically it can now just access the repo and resolve the dependencies. No user listing, no group listing, no sign in. But this is currently due to the lack of functionality in the gitlab package. Also I don't want right now to write my own node package for gitlab, may be somewhere in the future.
Also I currently reference to my branch of the gitlab package, as I found a bug in it while using it for this project.
@wzrdtales, so far it works great!
I have it running against a GitLab instance.
Just a note, on the following line, I had to change "develop"
to "master"
for it to fetch package.json
files correctly.
https://github.com/alanshaw/david-www/compare/master...wzrdtales:gitlab#diff-3d720a7af744286be3b1627fe3391e03R34
@alanshaw, question about moving foreword with this enhancement: Should we continue to work against @wzrdtales's branch, or maybe merge in what he has into a gitlab
branch on this project?
When do we consider the gitlab enhancement done?
I'm happy it helps you. I did forgot about the default branch, we're utilizing the gitlfow so I choosed the develop branch here.
I will make this configureable :)
For notice: i haven't opened a merge request for this, as this request is not complete. It can access repositories but not users. This is due to missing functionality in node-gitlab, I haven't the time yet to implement it myself.
Also I point for node-gitlab also to a custom branch from me, because of the following bug: https://github.com/node-gitlab/node-gitlab/pull/75
This is the reason why I haven't opened this for a pull request...
Pushed optionality to configure default branch.
Hi everyone, I'm one of the maintainer of node-gitlab
We are working to get node-gitlab/node-gitlab#75 fixed, so you will be able to use it, do not hesitate to ping me if I can help
+1
+1
@wzrdtales the problem of node-gitlab is fixed, are you going to make a PR?
@popomore I could do so, it is still incomplete to quote myself
For notice: i haven't opened a merge request for this, as this request is not complete. It can access repositories but not users. This is due to missing functionality in node-gitlab, I haven't the time yet to implement it myself.
It only supports the most important thing: resolving dependencies of your projects, but is lacking of the user listing and so on. If this does not matter I can open it as a PR no question.
+1
+1
+1
+1
Any progress?
+1
A new branch is online building on top of the current david-dm version. The old branch stopped working for us as there seem to be some incompatible apis that have been introduced, so I took action on this here again.
For everyone interested:
https://github.com/wzrdtales/david-www/tree/gitlabNew
This time I probably going to place a PR for this, also the structure needs a bit of rework to actually allow different platforms than github.
@wzrdtales what's the status of your fork right now?
@jakubzitny They have changed the structure of their project again, so I would need to rewrite that again.
However the current branch I posted is fully functional though, we are using it currently.
@wzrdtales Thanks for the info, I'll give it a try. 😉
Any news on this?
@luebken My fork is still functional, but not up to date with the latest version of david-dm though.
Haven't heard anything from @alanshaw in the whole discussion, though I also never submitted a PR. Anyone that feels he has a bit of spare time. Get my fork and rewrite it again, as david-dm had changed a lot from the last time I have looked at it. That was at the end of last year, so this is probably even more true than ever.
If your company is by any chance not afraid to invest money though: https://www.versioneye.com/enterprise
They just started their commercial plan for onpremise solutions, so that would be the money way to get it done. The other money way would be your company invests by giving one of your developers time to write the contribution to this product. Which would be of course the way better option, as giving back to open source is important and actually the reason why nearly any open source project needs to open commercial plans. Just b/c everyone thinks open source is free and they don't need to contribute back. Yes it is a sad world that we live in though...
However, I have other projects on my schedule currently, with way higher priority for me. So I am willing to rewrite this stuff again, but you probably have to wait a long time for it currently. If it is really important to all of you guys, I suggest, go open a bounty on https://www.bountysource.com/ and there will be most probably a developer getting on that task for you. That is a good option too though.
I have some free time this weekend, will pick this up 😄. Thanks for doing the work to help with this, will use your fork as reference!
got a work in progress branch and PR sent in here https://github.com/alanshaw/david-www/pull/382