https://github.com/werrett/rpm-recipes
Custom RPM recipes using FPM Cookery
https://github.com/werrett/rpm-recipes
centos devops fpm-cookery rpm
Last synced: about 1 year ago
JSON representation
Custom RPM recipes using FPM Cookery
- Host: GitHub
- URL: https://github.com/werrett/rpm-recipes
- Owner: werrett
- License: mit
- Created: 2016-12-27T08:27:47.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2016-12-29T11:25:41.000Z (over 9 years ago)
- Last Synced: 2025-02-16T04:43:53.949Z (over 1 year ago)
- Topics: centos, devops, fpm-cookery, rpm
- Language: Ruby
- Homepage:
- Size: 42 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# FPM Recipes
Various recipes to build custom RPMs. It uses
[FPM](https://github.com/jordansissel/fpm) and [FPM
Cookery](https://github.com/bernd/fpm-cookery) to build RPMs for RHEL-like
environments.
A CentOS build environment is provided using
[Vagrant](https://www.vagrantup.com/).
## Installation
Use the included `Vagrantfile` to build a CentOS 7 environment with all the
required dependencies. Simply run:
```bash
vagrant up
vagrant ssh
```
However, the list of prerequisites for building RPMs with FPM Cookery are:
* Ruby 2.0 or greater
* `git` `zlib` `zlib-devel` `openssl-devel` `readline-devel` RPMs
* `fpm-cookery` Ruby Gem
## Building RPMs
The included RPM build scripts are mounted in the Vagrant VM under `/vagrant`
To build single RPMs (eg. `Redis`):
```bash
cd /vagrant/redis
fpm-cook clean
fpm-cook
```
If you run into any problems, the partial build files are in the `tmp-build`
directory. Troubleshoot in there and then go through the cook steps above again.
Once an RPM is built you can examine, install and remove it via:
```bash
rpm -qpil pkg/new-package-name.version.rpm
sudo rpm -ivh pkg/new-package-name.version.rpm
sudo rpm -ev new-package-name
```
Included in the `scripts` directory are helpers to clean and build all the
include RPMs in one go:
```bash
cd /vagrant
./scripts/clean-all.sh
./scripts/cook-all.sh
```
## Creating an new RPM
```bash
cp -r example new-rpm-name
cd new-rpm-name
mv recipe.rb.example recipe.rb
vim recipe.rb
vim README.md
```
The example `recipe.rb` gives you the basic outline.
## Todo
* Include Puppet install with Vagrant VM
* Include `vboxsf` install with Vagrant VM
* Test build dependencies from basic Centos image
* Expand `VIM` plugins
* Debian-ize recipes and build apt packages