aboutsummaryrefslogtreecommitdiffstats
path: root/centos.sh
diff options
context:
space:
mode:
authorLoïc Hoguin <[email protected]>2018-04-18 00:27:06 +0200
committerLoïc Hoguin <[email protected]>2018-04-18 11:06:34 +0200
commite5311de35216cc541978c10a8f2cf8204acc7b94 (patch)
tree2346f74a488585a77fd1680cc1c827ee549bb9e0 /centos.sh
downloadci-e5311de35216cc541978c10a8f2cf8204acc7b94.tar.gz
ci-e5311de35216cc541978c10a8f2cf8204acc7b94.tar.bz2
ci-e5311de35216cc541978c10a8f2cf8204acc7b94.zip
Initial commit
Sets up LXC containers for CI for Alpine, Arch Linux, CentOS, Debian and Ubuntu. Currently only tested against Cowlib, it's likely that more packages need to be installed for the other projects.
Diffstat (limited to 'centos.sh')
-rwxr-xr-xcentos.sh25
1 files changed, 25 insertions, 0 deletions
diff --git a/centos.sh b/centos.sh
new file mode 100755
index 0000000..c2ff9a0
--- /dev/null
+++ b/centos.sh
@@ -0,0 +1,25 @@
+#!/usr/bin/env sh
+
+set -e
+#set -x
+
+NAME=$1
+DIST=centos
+RELEASE=7
+ARCH=amd64
+# We don't install Erlang because it's complicated on CentOS.
+# We will instead use the Erlang versions built with kerl.
+PACKAGES="curl ncurses-devel openssl-devel zsh vim sudo git make autoconf automake gcc"
+
+for f in ci.d/*; do source "$f"; done
+
+buildkite_stop $DIST
+lxc_destroy
+lxc_create $DIST $RELEASE $ARCH
+lxc_wait_for_ip
+yum_upgrade
+yum_install $PACKAGES
+buildkite_install $DIST $BUILDKITE_TOKEN
+ssh_copy_host_key
+ssh_copy_host_key buildkite-agent /var/lib/buildkite-agent
+lxc_restart