GithubHelp home page GithubHelp logo

mardiros / dotdeb Goto Github PK

View Code? Open in Web Editor NEW
0.0 3.0 0.0 8 KB

Debian Packaging, Docker, Aplty

License: BSD 3-Clause "New" or "Revised" License

Shell 12.76% Dockerfile 87.24%
debian packaging-tool

dotdeb's Introduction

Debian Packaging With Docker

Build you package, and host them with aptly using a docker container.

The aim of this container is for development purpose.

Setup

docker pull mardiros/dotdeb                     # Pull the docker image
mkdir -p ${HOME}/workspace/aptly/{aptly,root,sources.list.d}   # Create a directory to mount volumes

# Create an alias to keep "runtime" configuration of the container
alias dotdeb='docker run -t -i -v ${HOME}/workspace/aptly/repo:/aptly \
    -v ${HOME}/workspace/aptly/root:/root \
    -v $(pwd):/mnt \
    -v /dev/urandom:/dev/random \
    -v ${HOME}/workspace/aptly/sources.list.d:/etc/apt/sources.list.d \
    mardiros/dotdeb'

# Create a specific alias to expose the port
alias dotdeb-serve='docker run -t -i -v ${HOME}/workspace/aptly/repo:/aptly \
    -v ${HOME}/workspace/aptly/root:/root \
    -p 8765:8765 \
    mardiros/dotdeb \
    aptly serve -listen=:8765'

Note that the volume /dev/urandom:/dev/random is mount in order to facilitate the creation of the GPG key. The GPG key is saved in the /root volume, and the repo is created in the /aptly volume. The current dir is mounted in /mnt, it is used when building the debian package. The sources.list.d is mounted in /etc/apt/ to add new debian packages sources. The port 8765 will be used to serve the repository.

create the repository

dotdeb aptly -architectures=amd64 repo create -distribution=wheezy -component=main aptly-release

build a package

cd a_project_having_a_debian_directory
dotdeb makedeb

Push it in the repository

dotdeb aptly -architectures=amd64 repo add aptly-release *.deb
dotdeb aptly publish repo  -architectures=amd64  aptly-release

Note that for the next package, you don't have to publish it, but to update it with the command:

dotdeb aptly publish update wheezy

Run the packages repository

dotdeb-serve

Go further

Now, you can add the server in a new file in the directory ${HOME}/workspace/aptly/sources.list.d/.

Then, you can test that packages are instalable.

dotdeb /bin/bash
apt-get update
apt-get install my_package

dotdeb's People

Watchers

 avatar  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.