Closed mcrmonkey closed 5 months ago
That is not yet implemented, but I'd like to add that feature.
Ahh wonderful ! :heart: :tada:
Hello again,
FYI I started to work on that feature. I was already able to "mirror" gickup to codeberg. https://codeberg.org/buddyspencer/gickup
You can track the progress here: https://github.com/cooperspencer/gickup/pull/225/files
I am just not sure about the name for the parameter, selfmirror
sounds a bit weird.
Greetings, Excellent work!
Maybe name the parameter something like mirror
and give it a sub parameter of enabled
.
The MirrorInterval
parameter could be moved to live under that perhaps ...
example:
gitea:
...
mirror:
enabled: true
MirrorInterval: '8h0m0s'
:thinking: How would that play out for people who don't have that in their current config but do use gitea though ?
That wouldn't be a big deal. I'd just keep mirrorinterval
where it is right now as well and give a deprecation notice.
something like this
2024-04-12T11:58:01+02:00 INF mirroring gickup to http://127.0.0.1:3000/ stage=gitea url=http://127.0.0.1:3000/
2024-04-12T11:58:01+02:00 WRN mirrorinterval is deprecated and will be removed in the next release. please move it under the mirror parameter. stage=gitea url=http://127.0.0.1:3000/
is that clear enough?
:+1: I think that would be clear for me
I pushed a new release withe the fix
ooh, excellent work! Thank you !
I shall give it a test run shortly
:thinking: I don't appear to be having much success with this
Either omiting or including this config for a destination:
gitea:
...
mirror:
enabled: false
in the config still seems to trigger the mirror option causing the repo creation to be denied by codeberg
I can work around it in code but theres some further stuff that gets triggered an update is attempted
false
would be the default value, which means Forgejo/Gitea handle the process of mirroring the repo. If you set it to true
gickup will handle the mirror, basically cloning the repo and pushing it to codeberg.
https://cooperspencer.github.io/gickup-documentation/configuration/destination_docu/gitea
I created a blog post about mirroring to Codeberg. Maybe it helps you out here. https://cooperspencer.github.io/gickup-documentation/blog/codeberg-mirror
Ahhh! That makes more sense! I was coming at this with the view that disabling the mirroring would mean you wouldn't use the destinations mirroring features !
Not sure if I'm being a bit dim and missing it in the documentation but is it possible to have Gickup sync a source repo directly to an gitea/forgejo endpoint rather than use the mirroring features of the destination?
Why the ask; A gitea/forgejo endpoint ('codeberg' specifically) has mirroring turned off so any calls to the API requesting a mirror be setup receive an 'its turned off' message and so cannot proceed.