From 6542bb310db1b75377ebda050bde7b89178933ea Mon Sep 17 00:00:00 2001 From: Markus Pesch Date: Sun, 8 Mar 2020 16:30:59 +0100 Subject: [PATCH] add(any/aliases-dc): Init --- any/aliases-dc/.gitignore | 5 +++++ any/aliases-dc/Makefile | 5 +++++ any/aliases-dc/PKGBUILD | 15 +++++++++++++++ any/aliases-dc/docker-compose-aliases.sh | 9 +++++++++ 4 files changed, 34 insertions(+) create mode 100644 any/aliases-dc/.gitignore create mode 100644 any/aliases-dc/Makefile create mode 100644 any/aliases-dc/PKGBUILD create mode 100644 any/aliases-dc/docker-compose-aliases.sh diff --git a/any/aliases-dc/.gitignore b/any/aliases-dc/.gitignore new file mode 100644 index 0000000..cd75b66 --- /dev/null +++ b/any/aliases-dc/.gitignore @@ -0,0 +1,5 @@ +* +!*.sh +!.gitignore +!Makefile +!PKGBUILD \ No newline at end of file diff --git a/any/aliases-dc/Makefile b/any/aliases-dc/Makefile new file mode 100644 index 0000000..f5e1ac9 --- /dev/null +++ b/any/aliases-dc/Makefile @@ -0,0 +1,5 @@ +build: + makepkg --sign --force + +install: + makepkg --sign --force --install \ No newline at end of file diff --git a/any/aliases-dc/PKGBUILD b/any/aliases-dc/PKGBUILD new file mode 100644 index 0000000..b26a0ea --- /dev/null +++ b/any/aliases-dc/PKGBUILD @@ -0,0 +1,15 @@ +# Maintainer: Markus Pesch + +pkgname=aliases-dc +pkgver=0.1.0 +pkgrel=1 +pkgdesc="Markus Pesch's personal docker-compose aliases" +license=('GPL') +arch=('any') +source=("docker-compose-aliases.sh") +sha256sums=('999cb7bf30823487f23d2441507ee77ea3a7ff2a06e40b2087f2fe5dc4b134c9') +depends=("docker-compose") + +package() { + install -D --mode=0755 --target-directory=${pkgdir}/etc/profile.d ${srcdir}/docker-compose-aliases.sh +} diff --git a/any/aliases-dc/docker-compose-aliases.sh b/any/aliases-dc/docker-compose-aliases.sh new file mode 100644 index 0000000..0ca1e79 --- /dev/null +++ b/any/aliases-dc/docker-compose-aliases.sh @@ -0,0 +1,9 @@ +# Aliases for docker-compose +alias dcd='docker-compose down' # Stop and Remove containers +alias dcl='docker-compose logs' # Print all logs from the containers defined by the compose file on stdout +alias dclf='docker-compose logs --follow' # Print all and new logs from the containers defined by the compose file on stdout +alias dcp='docker-compose ps' # List all running containers +alias dcr='docker-compose rm --force' # Remove all defined containers +alias dcs='docker-compose stop' # Stop all defined containers +alias dcud='docker-compose up -d' # Start all defined containers +alias dcudb='docker-compose up -d --build' # Start all defomed containers and build them from source if possible