Textpattern CMS support forum
You are not logged in. Register | Login | Help
- Topics: Active | Unanswered
I'd like add a GitLab mirror of Textpattern
Hello all,
In an effort to not shun the tens to perhaps hundreds of thousands of people that GitHub rejects,
based upon their chosen browser(s). I’d like to sync up (mirror) the GitHub repo on GitLab.
Some time ago, I created a textpattern account on GitLab to (repeating myself)
1) Protect the (Project) name for Textpattern
2) So that I could insure access to Textpattern’ source. As GitHub doesn’t support my browser
Specifically; it’s not possible for anyone not using a (recent) mainline Mozilla browser to use GitHub (google recaptcha)
and other matters that GitHub itself has put in place to restrict usage. My browser is modern (recent) but is
based on Mozilla, not Mozilla (Firefox) itself. So I’m out where GitHub is concerned. The same is true for anyone using a
fork of the Google Chrome browser, as well.
Anyway, enough with the “rant” (sorry).
If anyone with the necessary (source) privs would be willing to assist me in getting GitLab access to the GitHub repo,
I’d be very grateful. Please message me. As the details of the conversation will likely need to contain “sensitive” information. :)
Thank you for all your time, and consideration.
—Chris
Offline
Re: I'd like add a GitLab mirror of Textpattern
GitLab supports automatic mirroring of a remote repository (infos here), so I guess you should be able to do this right away without needing any access credentials as the GitHub Textpattern repo is public anyway. Various other people have developed similar methods with a mirrored repo and crontab to schedule pulling updates at intervals (e.g. this serverfault thread).
I’m not sure how it works with making pull requests back to GitHub should you want to contribute to the code. Direct push access to the repo is only available to a few devs anyway, so all code submissions must be made as pull requests. Presumably that could be made via the command line or a git GUI app too – it is, after all, a regular git repo – so a browser is not absolutely necessary. Or have I missed your point?
TXP Builders – finely-crafted code, design and txp
Online
Re: I'd like add a GitLab mirror of Textpattern
Thanks for the reply, @jakpb
Regarding “automatic mirroring”:
GitLab says
Note: This feature is available for free to GitLab.com users until September 22nd, 2019.
But I’ll explore that further. My last experience attempting a mirror of a GitHub project
indicated the following:
Import repositories from GitHub
To import GitHub repositories, you first need to authorize GitLab to access the list of your GitHub repositories:
button: (link to initiate the action)
and
Alternatively, you can use a Personal Access Token. When you create your Personal Access Token, you will need to select the repo scope, so we can display a list of your public and private repositories which are available to import.
So this left me with the understanding that I’d need information not available to me.
My goal (personally) is to simply participate. As it is. This forum is my only option.
I think the same could be said for others also unable to use GitHub.
I could clone the repo, but I can’t participate because I can’t get an account on GitHub. So the (cloned) repo will
not be very useful except as something to hack on locally. IOW as far as I know, you cannot make pull requests
on/with GitHub without a GitHub account.
Thanks again for the reply, @jakob!
Offline
Re: I'd like add a GitLab mirror of Textpattern
Chris H wrote #318835:
Regarding “automatic mirroring”: GitLab says Note: This feature is available for free to GitLab.com users until September 22nd, 2019.
Hmm, that’s pretty soon :-( No idea why the time limit is there*. I think some of the other options mentioned in the forum thread I linked to employ similar means of pulling content over from a repository and automating.
Import repositories from GitHub … To import GitHub repositories, you first need to authorize GitLab to access the list of your GitHub repositories … you can use a Personal Access Token. When you create your Personal Access Token, you will need to select the repo scope, so we can display a list of your public and private repositories which are available to import.
I think that is a means of making it easy to transfer many/all repositories over from a GitHub account, including private repos. By accessing the GitHub account, you can then pick and choose which repo(s) you want and they’re brought over wholesale instead of having to mirror each repo individually. (There’s a similar mechanism with git-tower.com on a mac for mirroring the entire account or individual repos).
I could clone the repo, but I can’t participate because I can’t get an account on GitHub. So the (cloned) repo will not be very useful except as something to hack on locally. IOW as far as I know, you cannot make pull requests on/with GitHub without a GitHub account.
Yes, cloning – or using the above mirroring facility, or a clone with an other automated pull mechanism – should be possible in any case without having direct access to the GitHub account. Essentially that’s what contributors (such as myself occasionally) do at present when we’re not on the dev team itself: work locally on an own installation, update our online clone/fork and propose a change via a pull request and it gets accepted, modified, rejected/sent back for changes …
I don’t know how pull requests to a GitHub-hosted repo function without a GitHub account (conflicting reports here). Even if the pull request worked, I don’t know how the associated proposal, feedback and issue chat threads on GitHub will make their way back to GitLab. Maybe there’s a mechanism for that but I’ve never investigated it.
*Re, the time limit. If that facility is available to bona fide open-source organisations, maybe the Textpattern dev team can get an appropriate account without the time limit? That said, I can imagine having two sets of active codebases to monitor might end up being time-consuming for the already stretched devs. Maybe the devs can shed some light on this…
TXP Builders – finely-crafted code, design and txp
Online
Re: I'd like add a GitLab mirror of Textpattern
@jakob,
Thanks a lot for all the time, and effort of your reply.
I did some investigation as well. In the end all I really discovered is that I was able to “hijack” the (textpattern) repo — make an exact clone — but hijacking the origin. IOW making the (GitHub) textpattern origin (GitLab), or where ever else I wanted it to present itself as from. Worked a champ. But not my intended goal.
In the end maybe this is simply untenable. Seemed like git would have been flexible enough to create 2 (public) repos, with the master being out of GitHub, while “proxying” pushes, pulls, etc.. out of GitLab simultaneously.
Oh well. :(
Thanks again, @jakob!
—Chris
Offline
Re: I'd like add a GitLab mirror of Textpattern
I think this seems doable, as noted here. I’d need to read up on how to set it up and I don’t have any free time until end of September myself so if anyone else has time to work on the mirroring I can probably provide keys and hooks to them as requested.
Note that if this were to be implemented – I’d only want to see Gitlab used as a pull mirror, not a bidirectional mirror as that has the potential to mess up the repos really quickly.
Also note that…
Regarding “automatic mirroring”: GitLab says Note: This feature is available for free to GitLab.com users until September 22nd, 2019.
…only applied to private repos on Gitlab (as stated here) – so for public mirror repos on Gitlab of public repos on GitHub it’s always going to be free.
Offline
Re: I'd like add a GitLab mirror of Textpattern
philwareham wrote #318873:
I think this seems doable, as noted here.
That’s a GitLab Enterprise (read: pay-for) Edition doc, whether or not it’s possible for the freebie, non-CE edition…I don’t know. If we’re looking at this semi-seriously, then we might as well investigate a self-hosted Git instance, whether it’s GitLab, Gitea or any of the other myriad self-hosted options.
Offline
Re: I'd like add a GitLab mirror of Textpattern
Chris H wrote #318829:
Specifically; it’s not possible for anyone not using a (recent) mainline Mozilla browser to use GitHub (google recaptcha) and other matters that GitHub itself has put in place to restrict usage. My browser is modern (recent) but is based on Mozilla, not Mozilla (Firefox) itself. So I’m out where GitHub is concerned. The same is true for anyone using a fork of the Google Chrome browser, as well.
I’ll bite: what’s your browser? Tor? Something else? Genuinely interested in this from an ops point of view.
Offline
Re: I'd like add a GitLab mirror of Textpattern
gaekwad wrote #318902:
That’s a GitLab Enterprise (read: pay-for) Edition doc, whether or not it’s possible for the freebie, non-CE edition…I don’t know.
Oh, yes I think you are right – the feature to pull from a remote repository is a Bronze tier feature. The feature to push to a remote repository is free. How annoying. Oh well.
Offline