Git Product home page Git Product logo

docker-fpm's Introduction

Docker-fpm

Build Status

Summary

A docker image with FPM - Effing package management tool based on Debian Linux.
Build packages for multiple platforms (deb, rpm, etc) with great ease and sanity.

Repository name in Docker Hub: skandyla/fpm
Published via automated build mechanism

Docker image usage

Pull and tag (optional)

docker pull skandyla/fpm

Build on your own (optional)

docker build -t fpm .

FPM usage

fpm/wiki#usage

How to package files with fpm and docker-fpm image

Let's assume we want to package libvirt_exporter, which consist from two files, and they should be placed to:

/etc/systemd/system/multi-user.target.wants/libvirt-exporter.service
/usr/local/bin/libvirt_exporter

So create temporary directory first: $mkdir rpmbuild

Copy files to the rpmbuild directory assume it as a root path:

$tree rpmbuild/
rpmbuild/
├── etc
│   └── systemd
│       └── system
│           └── multi-user.target.wants
│               └── libvirt-exporter.service
└── usr
    └── local
        └── bin
            └── libvirt_exporter

Build rpm package:

$docker run --rm -v $(pwd):/data skandyla/fpm -s dir -t rpm -n "libvirt_exporter" -v 0.1 -p /data -C /data/rpmbuild ./

Example output:

{:timestamp=>"2018-02-11T13:46:37.459656+0000", :message=>"Created package", :path=>"/data/libvirt_exporter-0.1-1.x86_64.rpm"}

Verify package contents:

$rpm -qlp libvirt_exporter-0.1-1.x86_64.rpm
/etc/systemd/system/multi-user.target.wants/libvirt-exporter.service
/usr/local/bin/libvirt_exporter

License

MIT

docker-fpm's People

Contributors

bdeknijf avatar skandyla avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.