summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorScott W. Dunlop2015-12-27 18:39:53 -0800
committerScott W. Dunlop2015-12-27 18:41:19 -0800
commite819377de7f341fe6b415194fb749105b2303a40 (patch)
treeb19c07ed87296b4c1497b7956391563c5161d39a
downloadaur-e819377de7f341fe6b415194fb749105b2303a40.tar.gz
introduction of walter-git pkgbuild
-rw-r--r--.SRCINFO23
-rw-r--r--.gitignore4
-rw-r--r--PKGBUILD52
-rw-r--r--walter.install5
-rw-r--r--walter@.service23
5 files changed, 107 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..fb7608c34e96
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,23 @@
+# Generated by mksrcinfo v8
+# Mon Dec 28 02:41:01 UTC 2015
+pkgbase = walter-git
+ pkgdesc = a tiny deployment pipeline
+ pkgver = 1.3.0.r10.g393c3b7
+ pkgrel = 1
+ url = http://walter-cd.net/
+ install = walter.install
+ arch = x86_64
+ arch = i686
+ license = Apache
+ makedepends = git
+ makedepends = go
+ depends = glibc
+ provides = walter
+ conflicts = walter
+ source = walter::git+https://github.com/swdunlop/walter
+ source = walter@.service
+ md5sums = SKIP
+ md5sums = a8fbee5cdd303bcab7df3c22fadcbc51
+
+pkgname = walter-git
+
diff --git a/.gitignore b/.gitignore
new file mode 100644
index 000000000000..bf6f8366c2cc
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,4 @@
+pkg/
+src/
+walter-git-1.3.0.r10.g393c3b7-1-x86_64.pkg.tar.xz
+walter/
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..4d6dc63ed6c9
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,52 @@
+# Maintainer: Scott Dunlop <swdunlop@gmail.com>
+pkgname=walter-git
+pkgver=1.3.0.r10.g393c3b7
+pkgrel=1
+pkgdesc='a tiny deployment pipeline'
+arch=("x86_64" "i686") # probably arm; verification welcome
+url="http://walter-cd.net/"
+license=('Apache')
+groups=()
+depends=('glibc')
+makedepends=('git' 'go') # godep may use git when it fetches dependencies
+provides=("walter")
+conflicts=("walter")
+replaces=()
+backup=()
+options=()
+install='walter.install'
+noextract=()
+source=(
+ 'walter::git+https://github.com/swdunlop/walter'
+ 'walter@.service'
+)
+md5sums=('SKIP'
+ 'a8fbee5cdd303bcab7df3c22fadcbc51')
+
+# This version will not build, due to some missing dependencies -- swdunlop@gmail.com
+# pkgname=walter
+# pkgver=1.3.0
+# source=("https://github.com/walter-cd/walter/archive/v${pkgver}.zip")
+# md5sums=('844826f168778711aa7b5a98d5043045')
+
+# uses the last tag as a base, along with revision count and last commit hash (and trims off that v)
+pkgver() {
+ cd "$srcdir/walter"
+ git describe --long | sed 's/^v//;s/\([^-]*-g\)/r\1/;s/-/./g'
+}
+
+build() {
+ cd "$srcdir/walter"
+ ./build
+}
+
+check() {
+ cd "$srcdir/walter"
+ ./test.sh
+}
+
+package() {
+ cd "$srcdir/walter"
+ install -Dm0755 -o root -g root bin/walter "$pkgdir/usr/bin/walter"
+ install -Dm0644 -o root -g root "$srcdir/walter@.service" "$pkgdir/usr/lib/systemd/system/walter@.service"
+}
diff --git a/walter.install b/walter.install
new file mode 100644
index 000000000000..2703b0048fcb
--- /dev/null
+++ b/walter.install
@@ -0,0 +1,5 @@
+post_install() {
+ getent passwd walter-cd >/dev/null ||
+ useradd -rmU -d /var/lib/walter -c 'walter service user' walter-cd
+ install -o walter-cd -g walter-cd -dm0700 /etc/walter
+}
diff --git a/walter@.service b/walter@.service
new file mode 100644
index 000000000000..7e01e9956c87
--- /dev/null
+++ b/walter@.service
@@ -0,0 +1,23 @@
+[Unit]
+Description=A Tiny Deployment Pipeline
+After=network.target
+
+[Service]
+User=walter-cd
+EnvironmentFile=/etc/conf.d/walter
+Type=simple
+StandardOutput=syslog
+StandardError=syslog
+SyslogIdentifier=walter
+# walter can run both in an continuous service mode or a one-shot local mode
+ExecStart=/usr/bin/walter -c /etc/walter/%i.yml -mode service
+LimitCPU=infinity
+LimitFSIZE=infinity
+LimitDATA=infinity
+LimitCORE=0
+LimitAS=infinity
+LimitLOCKS=infinity
+
+[Install]
+WantedBy=multi-user.target
+