Repository Mirroring Tool
This tool allows you to mirror RPM repositories in your own private network. Organization (mirroring) credentials are required to mirror SUSE repositories.
The SLE RMT Book contains the end-user documentation for RMT. man
pages for rmt-cli
are located in the file MANUAL.md.
If you would like to contribute to RMT, please see our contribution guide.
If you would like to compare RMT to its predecessor SMT, please see our writeup.
Installation of RMT
Please view our guide to assist you in the RMT installation process.
Development Setup
- Install the system dependencies:
sudo zypper in libxml2-devel libxslt-devel libmariadb-devel gcc
- Install the ruby version specified in the
.ruby-version
file. - Install and start either the MariaDB or MySQL server:
sudo zypper in mariadb sudo systemctl enable mariadb sudo systemctl start mariadb
- Log into the MariaDB or MySQL server as root and create the RMT database user:
mysql -u root -p <<EOFF GRANT ALL PRIVILEGES ON \`rmt%\`.* TO rmt@localhost IDENTIFIED BY 'rmt'; FLUSH PRIVILEGES; EOFF
- Clone the RMT repository:
git clone git@github.com:SUSE/rmt.git
- Install the ruby dependencies:
cd rmt bundle install
- Copy the file
config/rmt.yml
toconfig/rmt.local.yml
. With this file, override the following default settings:- Add your organization credentials to
scc
section. - Ensure that the
database
section is correct.
- Add your organization credentials to
- Create the directory
/var/lib/rmt
and ensure that your current user owns it.sudo mkdir /var/lib/rmt sudo chown -R $(id -u):$(id -g) /var/lib/rmt
- Create the development database:
bin/rails db:create db:migrate
- Verify that RMT works:
- Run the command
bin/rails server -b 0.0.0.0
to start the web server. - Run the command
bin/rmt-cli sync
to sync RMT with SCC.
- Run the command
Development Setup - docker-compose
In order to run the application locally using docker-compose:
- Copy the
.env.example
file to.env
. - Add your organization credentials to
.env
file. Mirroring credentials can be obtained from the SUSE Customer Center. - Start
docker-compose
and build the containers:docker-compose up --build
- The web server is accessible at http://localhost:8080/. This URL can be used for registering clients.
- To start a shell inside the RMT docker container, run the following command:
docker-compose exec rmt bash
API documentation
RMT partially implements the SUSE Customer Center API. You can read the details of each endpoint to find out whether they are supported by RMT.
Feedback
Do you have suggestions for improvement? Let us know!
Go to Issues, create a new issue and describe what you think could be improved.
Feedback is always welcome!
Security Policy
Please see our security policy for more information.