mirror-to-gitea/README.md
README.mdRaw
1# Mirror your github repositories to your gitea server
2
3This script mirrors automatically the public repositories from a github-user or github-organization to your gitea server.
4It will - once started - create a mirrored repository under a given token for a gitea user fully automatically.
5
6Example:
7A github user `github-user` has public repositories `dotfiles` and `zsh-config`.
8Starting the script with a gitea token for the account `gitea-user` will create the following mirror repositories:
9
10- github.com/github-user/dotfiles ← some-gitea.url/gitea-user/dotfiles
11- github.com/github-user/zsh-config ← some-gitea.url/zsh-config/dotfiles
12
13The mirror settings are default by your gitea instance.
14
15## Prerequisites
16
17- Something to mirror (a github user or organization with public repos)
18- Gitea instance up and running
19- User for Gitea with generated token
20- Docker
21
22## Run it
23
24```sh
25docker container run \
26 -d \
27 --restart always \
28 -e GITHUB_USER=github-user \
29 -e GITEA_URL=https://some-gitea.url \
30 -e GITEA_TOKEN=please-exchange-with-token \
31 jaedle/mirror-to-gitea:latest
32```
33
34### Parameters
35
36- `GITHUB_USER` name of users which public repos should be mirrored
37- `GITEA_URL` url of your gitea server
38- `GITEA_TOKEN` token for your gitea user
39
40## Things to do
41
42- configurable interval
43- better logging
44- use github token to solve problems with rate limits
45- add gitlab support
46- and so on..