summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNicolas Braud-Santoni <nicoo@ffgraz.net>2016-08-07 19:21:05 +0200
committerNicolas Braud-Santoni <nicoo@ffgraz.net>2016-08-07 20:38:54 +0200
commit54032c8c4cae71b5d18d1e30acbb364da90453a5 (patch)
treed3c5ecedc7ea97707b44257056a41dfe3d71ebfa
parentb6ca062670b342344df08b53fb216db619ef42bc (diff)
Containerize manman
-rw-r--r--config/environment.rb2
-rw-r--r--gemrc2
-rw-r--r--manifest.yaml73
3 files changed, 76 insertions, 1 deletions
diff --git a/config/environment.rb b/config/environment.rb
index a1b5a8a..1e3931b 100644
--- a/config/environment.rb
+++ b/config/environment.rb
@@ -5,7 +5,7 @@
# ENV['RAILS_ENV'] ||= 'production'
# Specifies gem version of Rails to use when vendor/rails is not present
-RAILS_GEM_VERSION = '1.2.1'
+RAILS_GEM_VERSION = '1.2.6'
# Bootstrap the Rails environment, frameworks, and default configuration
require File.join(File.dirname(__FILE__), 'boot')
diff --git a/gemrc b/gemrc
new file mode 100644
index 0000000..330fd29
--- /dev/null
+++ b/gemrc
@@ -0,0 +1,2 @@
+install: --no-document
+update: --no-document
diff --git a/manifest.yaml b/manifest.yaml
new file mode 100644
index 0000000..71441ed
--- /dev/null
+++ b/manifest.yaml
@@ -0,0 +1,73 @@
+---
+name: manman
+
+provider:
+ name: docker
+ dockerfile:
+ - USER manman
+ - WORKDIR /srv/manman
+ - CMD script/server
+ - EXPOSE 3000
+ labels:
+ name: "manman-{system.release}-{system.architecture}-{%y}{%m}{%d}"
+ description: "{system.release} container for legacy manman"
+
+bootstrapper:
+ workspace: /opt/bootstrap-vz
+ variant: minbase
+
+system:
+ release: squeeze
+ architecture: amd64
+ bootloader: none
+ charmap: UTF-8
+ hostname: manman
+ locale: en_US
+ timezone: Europe/Vienna
+
+volume:
+ backing: folder
+ partitions:
+ type: none
+ root:
+ filesystem: ext4
+ size: 1GiB
+
+packages:
+ components: [main, contrib, non-free]
+ mirror: http://debian.ffgraz.net/archive
+
+# sources:
+# main:
+# - deb [check-valid-until=no] http://debian.ffgraz.net/archive squeeze-lts main contrib non-free
+
+ install:
+ - adduser
+ - ruby
+ - rubygems
+
+
+plugins:
+ file_copy:
+ files:
+ - src: .
+ dst: /srv/manman
+ - src: gemrc
+ dst: /etc/
+
+ commands:
+ commands:
+ - [chroot, '{root}', gem, install, -v=0.8.7, rake]
+ - [chroot, '{root}', gem, install, -v=1.2.6, rails]
+ - [chroot, '{root}', adduser, --system, --group,
+ --home, /var/lib/manman, manman]
+
+ minimize_size:
+ apt:
+ autoclean: true
+ languages: [none]
+ gzip_indexes: true
+ autoremove_suggests: true
+ dpkg:
+ locales: []
+ exclude_docs: true