smeserver-koji/README.md

73 lines
3.0 KiB
Markdown
Raw Normal View History

2023-09-01 08:45:16 +02:00
# ![smeserver-koji](https://www.koozali.org/images/koozali/Logo/Png/Koozali_logo_2016.png)
2023-08-28 06:37:57 +02:00
2023-09-01 07:47:09 +02:00
## Koji Setup Scripts
2023-08-28 06:44:38 +02:00
The purpose of these scripts it to enable setting up a koji environment quickly
with reasonable configurations.
2023-09-28 13:25:33 +02:00
These scripts were originally borrowed from Clear Linux and heavily modified to suit the smeserver (Koozali.org) setup.
Thanks to George T Kramer for doing a lot of the prework for these over at Clear Linux.
2023-08-28 06:48:40 +02:00
2023-09-01 07:47:09 +02:00
### Assumptions
2023-08-28 06:44:38 +02:00
* All scripts are run as the root user
* The root user has a password set
2023-08-28 07:44:59 +02:00
* These are run on a bare Rocky 8 minimal install
2023-08-28 06:44:38 +02:00
* Basic configurations (e.g. network, time, etc.) have been applied
2023-09-01 07:47:09 +02:00
* servers are reachable by their FQDNs (DNS or you've added them into the appropriate /etc/hosts files)
2023-09-28 13:23:50 +02:00
* Koji web server can exist on the hub or it's own server
2023-09-02 09:32:36 +02:00
* Koji builder can exist on the hub or multiple build servers
2023-08-28 06:44:38 +02:00
### Installing
2023-09-01 07:47:09 +02:00
2023-09-11 09:09:33 +02:00
The install script will install all required components on the hub, web and build servers.
2023-09-01 08:41:59 +02:00
You will need to fill in some information on the way through.
2023-09-02 09:32:36 +02:00
* info for your ssl certs (Country, State, City, Org, Org Unit)
2023-09-11 09:06:57 +02:00
* If you have a separate web server:
* accept the ECDSA key fingerprint of the web server
* enter the root password for the web server
2023-09-11 09:04:44 +02:00
* For each build server:
* accept the ECDSA key fingerprint of the build server
* enter the root password for the build server
2023-09-02 09:32:36 +02:00
2023-10-02 01:17:11 +02:00
On your koji hub server (as root):
2023-09-01 08:41:59 +02:00
2023-09-02 09:37:59 +02:00
curl https://src.koozali.org/smedev/smeserver-koji/raw/branch/master/install-koji-farm.sh > install-koji-farm.sh
chmod o+x install-koji-farm.sh
./install-koji-farm.sh
2023-09-01 07:47:09 +02:00
2023-09-11 08:57:02 +02:00
There are optional parameters available on the install-koji-farm.sh script
2023-11-07 23:45:59 +01:00
install-koji-farm.sh [web=<web server FQDN> | build=<build server FQDN> | scm=<IP or Name of SCM>:/* | debug]
2023-09-11 08:57:02 +02:00
2023-09-15 08:06:15 +02:00
* No parameters will deploy an all-in-one server with the web and builder installed on the hub.
* You can have multiple build=\<builder FQDN\> parameters.
2023-11-07 23:45:59 +01:00
* You can have multiple scm= parameters which will be added to the allowed SCMS
2023-09-11 09:09:33 +02:00
* debug will print each command executed and be very noisy (still noisy without)
2023-09-11 08:57:02 +02:00
2023-09-11 08:59:36 +02:00
The web interface will be available at http://\<web FQDN\>/koji
2023-09-05 00:51:29 +02:00
2023-09-04 10:47:39 +02:00
### Adding additional Build servers
2023-09-01 07:47:09 +02:00
2023-09-04 10:55:31 +02:00
To add additional build servers into your farm, just run the following script on your hub as root
2023-08-28 06:44:38 +02:00
2023-09-04 10:47:39 +02:00
koji-add-builder.sh <FQDN of new build server> [debug]
2023-08-28 06:44:38 +02:00
### Adding Users
You can add Users for both the CLI and Web
2023-09-06 02:31:12 +02:00
koji-add-user <User Name> [ permisssion=<permissions> | debug ]
This will add them into the db and generate ssl CLI and browser keys, which will be bundled up in a tgz file at /etc/pki/koji/bundle/koji-\<User Name\>-bundle.tgz.
2023-10-02 01:17:11 +02:00
This bundle should be extracted in their home (~) directory (either on the hub or any device with the koji client installed) and will create a .koji directory with cli config and keys.
cd ~
tar -zxf koji-\<User Name\>-bundle.tgz
2023-09-04 10:47:39 +02:00
### Other components
2023-08-28 06:44:38 +02:00
2023-09-04 10:47:39 +02:00
The other scripts in the repository are used by the install-koji-farm.sh and koji-add-builder.sh scripts or I'm still experimenting with them :)