Fedora/EPEL packaging
859
That project produces Fedora/CentOS-based Docker images, hosted on dedicated public Docker Cloud site. Those Docker images are intended to ease the maintenance work of official Fedora/EPEL RPM packagers.
That project initially took its inspiration from Alan Franzoni's own initiative.
Every time some changes are committed on the project's GitHub repository, the Docker images are automatically rebuilt and pushed onto Docker Cloud.
For most of Fedora/EPEL RPM packaging needs, picking the Docker image corresponding to the targeted Fedora/EPEL release is enough.
When the pre-requisites of the packaging procedure become too heavy, however,
the Docker image may be amended so as to add that pre-requisite procedure.
The preferred way to propose amendment of the Docker image is through
pull requests on the GitHub
project.
Once the pull request has been merged, i.e., once the Dockerfile
amendment has been committed in
GitHub,
Docker Cloud then rebuilds the corresponding Docker image, which becomes
available for every one to use.
$ mkdir -p ~/.keytab
$ ktutil
ktutil: addent -password -p <fas-username>@FEDORAPROJECT.ORG -k 1 -e des-cbc-md5
Password for <fas-username>@FEDORAPROJECT.ORG:
ktutil: wkt <fas-username>.keytab
ktutil: quit
$ mv <fas-username>.keytab ~/.keytab
$ kinit <fas-username>@FEDORAPROJECT.ORG -k -t ~/.keytab/<fas-username>.keytab
<fedora-or-epel-version> may be one of rawhide, fedora37,
fedora36, epel9, epel8 or epel7):$ docker pull infrahelpers/fedorapackaging:<fedora-or-epel-version>
$ docker run --rm --privileged=true -v ~/.ssh/id_rsa:/home/build/.ssh/id_rsa -v ~/.ssh/id_rsa.pub:/home/build/.ssh/id_rsa.pub -it infrahelpers/fedorapackaging:<fedora-or-epel-version>
[[email protected] fedora_packaging]$
[[email protected] fedora_packaging]$ kinit <fas-username>@FEDORAPROJECT.ORG
Password for <fas-username>@FEDORAPROJECT.ORG:
[[email protected] fedora_packaging]$ export FULLNAME="Firstname Lastname"
[[email protected] fedora_packaging]$ export EMAIL="[email protected]"
[[email protected] fedora_packaging]$ git config --global user.name "$FULLNAME"
[[email protected] fedora_packaging]$ git config --global user.email "$EMAIL"
[[email protected] fedora_packaging]$ sed -i -e "s/Firstname Lastname/$FULLNAME/g" ~/.rpmmacros
[[email protected] fedora_packaging]$ sed -i -e "s/[email protected]/$EMAIL/g" ~/.rpmmacros
[[email protected] fedora_packaging]$ MYPACKAGE=boost
[[email protected] fedora_packaging]$ fedpkg clone $MYPACKAGE
Cloning into 'boost'...
Enter passphrase for key '/home/build/.ssh/id_rsa':
remote: Counting objects: 1814, done.
remote: Compressing objects: 100% (1515/1515), done.
remote: Total 1814 (delta 964), reused 592 (delta 279)
Receiving objects: 100% (1814/1814), 2.09 MiB | 1.64 MiB/s, done.
Resolving deltas: 100% (964/964), done.
[[email protected] fedora_packaging]$ cd $MYPACKAGE
source files (mainly, source tarballs and patches):[[email protected] boost]$ fedpkg sources
Downloading boost_1_72_0.tar.bz2
################################################### 100.0%
[[email protected] boost]$ vi $MYPACKAGE.spec
[[email protected] boost]$ git add $MYPACKAGE.spec
[[email protected] boost]$ fedpkg local
mock:[[email protected] boost]$ fedpkg mockbuild --root fedora-rawhide-x86_64
[[email protected] fedora_packaging]$ cdbuild
[[email protected] SPECS]$ rpmbuild -bs $MYPACKAGE.spec
[[email protected] SPECS]$ koji build --arch-override=x86_64 --scratch --nowait rawhide /home/build/dev/packages/SRPM/$MYPACKAGE-$MYVER.src.rpm
[[email protected] boost]$ cp -a *.{patch,bz2,so} ~/dev/packages/SOURCES
[[email protected] boost]$ cp *.spec ~/dev/packages/SPECS
[[email protected] boost]$ cdbuild
[[email protected] SPECS]$ rpmbuild -ba $MYPACKAGE.spec
[[email protected] SPECS]$ cd -
[[email protected] boost]$ fedpkg clog
[[email protected] boost]$ fedpkg commit -F clog -p
[[email protected] boost]$ fedpkg build --nowait
[[email protected] boost]$ exit
$ docker kill infrahelpers/fedorapackaging:<fedora-or-epel-version>
The images may be customized, and pushed to Docker Hub:
<fedora-or-epel-version> may be one of rawhide, fedora31,
fedora30, epel8, epel7 or epel6
$ mkdir -p ~/dev/fedora
$ cd ~/dev/fedora
$ git clone https://github.com/fedorapackaging/docker-images.git
$ cd docker-images
$ vi <fedora-or-epel-version>/Dockerfile
$ docker build -t infrahelpers/fedorapackaging:<fedora-or-epel-version> <fedora-or-epel-version>/
$ docker run --rm --privileged=true -v ~/.ssh/id_rsa:/home/build/.ssh/id_rsa -v ~/.ssh/id_rsa.pub:/home/build/.ssh/id_rsa.pub -it infrahelpers/fedorapackaging:<fedora-or-epel-version>
[[email protected] fedora_packaging]$ exit
$ docker push infrahelpers/fedorapackaging:<fedora-or-epel-version>
For any of the following features, an issue may be open on GitHub:
rawhide-java, epel8-cpp,
fedora37-scala)Content type
Image
Digest
sha256:86ba8d6b7…
Size
1.2 GB
Last updated
almost 4 years ago
docker pull infrahelpers/fedorapackaging:epel8