{"id":19251203,"url":"https://github.com/rexops/repositorio","last_synced_at":"2025-04-21T12:34:01.023Z","repository":{"id":14886819,"uuid":"17610473","full_name":"RexOps/repositorio","owner":"RexOps","description":"Tool to administrate linux repositories","archived":false,"fork":false,"pushed_at":"2022-01-15T21:03:46.000Z","size":240,"stargazers_count":55,"open_issues_count":30,"forks_count":18,"subscribers_count":10,"default_branch":"master","last_synced_at":"2024-05-09T19:36:29.182Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"http://www.repositor.io/","language":"Perl","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/RexOps.png","metadata":{"files":{"readme":"README.md","changelog":"ChangeLog","contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2014-03-10T22:14:39.000Z","updated_at":"2023-09-25T02:51:38.000Z","dependencies_parsed_at":"2022-07-12T15:13:30.884Z","dependency_job_id":null,"html_url":"https://github.com/RexOps/repositorio","commit_stats":null,"previous_names":[],"tags_count":7,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RexOps%2Frepositorio","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RexOps%2Frepositorio/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RexOps%2Frepositorio/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/RexOps%2Frepositorio/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/RexOps","download_url":"https://codeload.github.com/RexOps/repositorio/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":223865334,"owners_count":17216496,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-09T18:20:58.686Z","updated_at":"2024-11-09T18:20:59.281Z","avatar_url":"https://github.com/RexOps.png","language":"Perl","funding_links":[],"categories":[],"sub_categories":[],"readme":"## repositorio - A tool to mirror and administrate linux repositories.\n\nrepositorio is a tool to mirror and administrate linux repositories and to tag them.\n\nThis is the master branch of the development repository. In this branch you'll find all the new stuff that is work-in-progress.\n\n### Need help?\n\nIf you need help, feel free to join us on irc.freenode.net on channel #rex (this is the channel for all RexOps projects) or just post an issue in the tracker.\n\n### Supported Repositories\n\nRight now *yum*, *apt* and *yast (opensuse)* repositories are supported. It is also possible to query errata for packages if an errata database is present. See *errata* chapter for more information.\n\nCurrently we're working on *docker* support, so that it is possible to build a private docker registry with repositorio. See *docker* chapter for more information.\n\nYaST (OpenSuSE) repository support is only for mirroring. If you want to create custom repositories for your SuSE systems, repositorio will create yum repositories. You can add those repositories with the following command:\n\n```\nzypper ar -t YUM http://my-repo-server.domain.tld/head/my-repo/ my-repo\n```\n\n\n### Configuration\n\nTo configure repositorio create a configuration file */etc/rex/repositorio.conf*. For an example file please see *repositorio.conf* file in this repository.\n\n```\nRepositoryRoot = /data/repositories\n\n\u003cLog4perl\u003e\n  config = log4perl.conf\n\u003c/Log4perl\u003e\n\n\n# this will create the repository inside\n# /data/repositories/head/rex-centos-6-x86-64/CentOS/6/rex/x86_64\n\u003cRepository rex-centos-6-x86-64\u003e\n  url   = http://nightly.rex.linux-files.org/CentOS/6/rex/x86_64\n  local = rex-centos-6-x86-64/CentOS/6/rex/x86_64\n  type  = Yum\n\u003c/Repository\u003e\n```\n\nYou also need to create a Log4perl configuration file. You can set the location in repositorio.conf file.\n\n```\nlog4perl.rootLogger                    = DEBUG, FileAppndr1\n\nlog4perl.appender.FileAppndr1          = Log::Log4perl::Appender::File\nlog4perl.appender.FileAppndr1.filename = /var/log/repositorio.log\nlog4perl.appender.FileAppndr1.layout   = Log::Log4perl::Layout::SimpleLayout\n```\n\n### Mirror a repository\n\nTo mirror a defined repository you can use the following command:\n\n```\nrepositorio --mirror --repo=rex-centos-6-x86-64\n```\n\nTo mirror every configured directory, you can use the **all** keyword.\n\n```\nrepositorio --mirror --repo=all\n```\n\nTo reload the metadata of a repository there is the *--update-metadata* option.\n\n```\nrepositorio --mirror --repo=rex-centos-6-x86-64 --update-metadata\n```\n\nTo reload all package files of a repository there is the *--update-files* option.\n\n```\nrepositorio --mirror --repo=rex-centos-6-x86-64 --update-files\n```\n\n### Managing a repository\n\nIf you need to create a custom repository, you can do this as well.\n\nJust add the repository to your configuration file:\n\n```\n\u003cRepository custom-centos-6-x86-64\u003e\n  local = custom-centos-6-x86-64/CentOS/6/custom/x86_64/\n  type  = Yum\n\u003c/Repository\n```\n\nInitialize the repository:\n\n```\nrepositorio --init --repo=custom-centos-6-x86-64\n```\n\nNow you can add and remove files from this directory.\n\n```\nrepositorio --add-file=my-package-1.0.rpm --repo=custom-centos-6-x86-64\nrepositorio --remove-file=my-package-0.9.rpm --repo=custom-centos-6-x86-64\n```\n\n\n### Tagging\n\nEvery repository is per default stored in the *head* tag. If you want to create stable tags for your production servers,\nyou can do this with the *--tag* option.\n\nA tag is just a hardlinked copy of the *head* tag.\n\n```\nrepositorio --tag=production --repo=rex-centos-6-x86-64\n```\n\n### Errata\n\nIt is also possible to query repositorio for the errata of a package. You can do this via command line and via a webservice. If you want to query errata you also need the errata database. Currently we provide CentOS (5, 6 and 7) and EPEL errata databases.\n\nIf you want to contribute scripts to generate errata databases for other distributions, feel free to send us a pull request or join us on irc (irc.freenode.net / #rex).\n\nTo configure a repository to serve also the errata, you need to configure the errata type for the repository.\n\n```\n\u003cRepository centos-6-x86-64\u003e\n  url    = http://ftp.hosteurope.de/mirror/centos.org/6/os/x86_64/\n  local  = centos-6-x86-64/CentOS/6/rex/x86_64/\n  type   = Yum\n  errata = CentOS-6\n\u003c/Repository\u003e\n```\n\nTo query the errata database you can run the following command:\n\n```\nrepositorio --repo=some-repo --errata --package=openssl --arch=x86_64 --version=1.0.0-20.el6_2.3\n```\n\nIf you want to query the webinterface, this will return a json structure containing all available updates:\n\n```\ncurl -XGET \\\n  http://your-server:3000/head/centos-6-x86-64/errata?package=openssl\u0026arch=x86_64\u0026version=1.0.0-20.el6_2.3\n```\n\nTo update the errata database you can use the following command:\n\n```\nrepositorio --repo=centos-6-x86-64 --update-errata\n```\n\nThe following errata types are available:\n\n* CentOS-5\n* CentOS-6\n* CentOS-7\n* epel-5\n* epel-6\n* epel-7\n\n### Serving a directory\n\nTo serve a directory we advice you to use Apache or nginx. You can just point the document root to *RepositoryRoot* in your repositorio.conf file.\n\nIf you don't want to install a webserver, you can also use the build-in webserver to server repositories.\n\n```\nrepositorio --repo=repo-name --server prefork\n```\n\n### Docker\n\nIf you also want to manage your private docker registry with repositorio you can do this as well. Currently this feature is in an early development stage. We welcome any feedback and patches.\n\nCurrent development stage:\n\n* upload images (docker push) - done\n* download images (docker pull) - done\n* authentication (docker login) - done\n* user management - open\n* permissions to repositories - open\n* search for images (docker search) - done\n\n#### Configuration\n\nTo create a docker repository you need the following snippet inside your repositorio.conf file.\n\n```\n\u003cRepository docker\u003e\n  local = docker-images\n  type  = Docker\n\u003c/Repository\u003e\n```\n\nAnd then you can initialize this repository as usual with:\n\n```\nrepositorio --repo=docker --init\n```\n\nThis will create a new folder *docker-images* inside your *RepositoryRoot*/head directory.\n\nFor the docker images it is not possible to use apache (or another webserver) to serve the content, so you need to start a small server that is included with repositorio.\n\n```\nrepositorio --repo=docker --server prefork\n```\n\nThis will start a preforking webserver. The server part is done with Mojolicious. Mojolicious is an easy to use Perl Webframework.\n\nNow you can use *repositorio* as a docker registry.\n\nFirst you need to create a user:\n\n```\ndocker login -e some@mail.tld -p 'some-save-password' -u 'some-user' http://localhost:3000/v1/\n```\n\nThe user is enabled immediately.\nThen you can push and pull images.\n\n```\ndocker pull ubuntu\ndocker tag localhost:3000/ubuntu\ndocker push localhost:3000/ubuntu\n```\n\n\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frexops%2Frepositorio","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frexops%2Frepositorio","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frexops%2Frepositorio/lists"}