summaryrefslogtreecommitdiff
path: root/app-emulation/lxd/files
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
committerV3n3RiX <venerix@redcorelinux.org>2018-07-14 21:03:06 +0100
commit8376ef56580626e9c0f796d5b85b53a0a1c7d5f5 (patch)
tree7681bbd4e8b05407772df40a4bf04cbbc8afc3fa /app-emulation/lxd/files
parent30a9caf154332f12ca60756e1b75d2f0e3e1822d (diff)
gentoo resync : 14.07.2018
Diffstat (limited to 'app-emulation/lxd/files')
-rw-r--r--app-emulation/lxd/files/de-translation-newline.patch20
-rw-r--r--app-emulation/lxd/files/ja-translation-newline.patch11
-rw-r--r--app-emulation/lxd/files/lxd-dont-go-get.patch16
-rw-r--r--app-emulation/lxd/files/lxd.confd27
-rw-r--r--app-emulation/lxd/files/lxd.confd.124
-rw-r--r--app-emulation/lxd/files/lxd.initd46
-rw-r--r--app-emulation/lxd/files/lxd.service10
7 files changed, 154 insertions, 0 deletions
diff --git a/app-emulation/lxd/files/de-translation-newline.patch b/app-emulation/lxd/files/de-translation-newline.patch
new file mode 100644
index 000000000000..9ef55ab2f0ee
--- /dev/null
+++ b/app-emulation/lxd/files/de-translation-newline.patch
@@ -0,0 +1,20 @@
+--- /po/de.po 2018-06-27 19:57:56.759130047 -0500
++++ /po/de.po 2018-06-27 20:01:09.694634346 -0500
+@@ -65,7 +65,7 @@
+ "### type: custom\n"
+ "### used_by: []\n"
+ "### config:\n"
+-"### size: \"61203283968\""
++"### size: \"61203283968\"\n"
+ msgstr ""
+ "### Dies ist eine Darstellung der Eigenschaften eines Abbildes in yaml.\n"
+ "### Jede Zeile die mit '# beginnt wird ignoriert.\n"
+@@ -167,7 +167,7 @@
+ "###\n"
+ "### Each property is represented by a single line:\n"
+ "### An example would be:\n"
+-"### description: My custom image"
++"### description: My custom image\n"
+ msgstr ""
+ "### Dies ist eine Darstellung der Eigenschaften eines Images in yaml.\n"
+ "### Jede Zeile die mit '# beginnt wird ignoriert.\n"
diff --git a/app-emulation/lxd/files/ja-translation-newline.patch b/app-emulation/lxd/files/ja-translation-newline.patch
new file mode 100644
index 000000000000..bbda24c6f37e
--- /dev/null
+++ b/app-emulation/lxd/files/ja-translation-newline.patch
@@ -0,0 +1,11 @@
+--- /po/ja.po 2018-05-20 19:42:38.932990198 -0500
++++ /po/ja.po 2018-05-20 19:42:55.839944861 -0500
+@@ -1380,7 +1380,7 @@
+ "イメージのエイリアスを一覧表示します\n"
+ "\n"
+ "指定するフィルタはイメージのハッシュ値の一部でもイメージのエイリアスの一部で"
+-"も構いません。"
++"も構いません。\n"
+
+ #: lxc/image.go:888
+ msgid "List images"
diff --git a/app-emulation/lxd/files/lxd-dont-go-get.patch b/app-emulation/lxd/files/lxd-dont-go-get.patch
new file mode 100644
index 000000000000..a6e25e325b95
--- /dev/null
+++ b/app-emulation/lxd/files/lxd-dont-go-get.patch
@@ -0,0 +1,16 @@
+--- /src/github.com/lxc/lxd/Makefile.orig 2016-07-11 23:34:40.299664675 +0000
++++ /src/github.com/lxc/lxd/Makefile 2016-07-11 23:37:00.816018727 +0000
+@@ -13,13 +13,11 @@
+
+ .PHONY: default
+ default:
+- go get -t -v -d ./...
+ go install -v $(TAGS) $(DEBUG) ./...
+ @echo "LXD built successfully"
+
+ .PHONY: client
+ client:
+- go get -t -v -d ./...
+ go install -v $(TAGS) $(DEBUG) ./lxc
+ @echo "LXD client built successfully"
+
diff --git a/app-emulation/lxd/files/lxd.confd b/app-emulation/lxd/files/lxd.confd
new file mode 100644
index 000000000000..3d553276a5e3
--- /dev/null
+++ b/app-emulation/lxd/files/lxd.confd
@@ -0,0 +1,27 @@
+# Group which owns the shared socket
+LXD_OPTIONS+=" --group lxd"
+
+
+
+# Enable cpu profiling into the specified file
+#LXD_OPTIONS+=" --cpuprofile /tmp/lxc_cpu_profile"
+
+# Enable memory profiling into the specified file
+#LXD_OPTIONS+=" --memprofile /tmp/lxc_mem_profile"
+
+
+
+# Enables debug mode
+#LXD_OPTIONS+=" --debug"
+
+# For debugging, print a complete stack trace every n seconds
+#LXD_OPTIONS+=" --print-goroutines-every 5"
+
+# Enables verbose mode
+#LXD_OPTIONS+=" -v"
+
+# Logfile to log to
+#LXD_OPTIONS+=" --logfile /var/log/lxd/lxd.log"
+
+# Enables syslog logging
+#LXD_OPTIONS+=" --syslog"
diff --git a/app-emulation/lxd/files/lxd.confd.1 b/app-emulation/lxd/files/lxd.confd.1
new file mode 100644
index 000000000000..8e342cc62d16
--- /dev/null
+++ b/app-emulation/lxd/files/lxd.confd.1
@@ -0,0 +1,24 @@
+# Group which owns the shared socket
+LXD_OPTIONS+=" --group lxd"
+
+
+
+# Enable cpu profiling into the specified file
+#LXD_OPTIONS+=" --cpuprofile /tmp/lxc_cpu_profile"
+
+# Enable memory profiling into the specified file
+#LXD_OPTIONS+=" --memprofile /tmp/lxc_mem_profile"
+
+
+
+# Enables debug mode
+#LXD_OPTIONS+=" --debug"
+
+# For debugging, print a complete stack trace every n seconds
+#LXD_OPTIONS+=" --print-goroutines 5"
+
+# Enables verbose mode
+#LXD_OPTIONS+=" --verbose"
+
+# Logfile to log to
+#LXD_OPTIONS+=" --logfile /var/log/lxd/lxd.log"
diff --git a/app-emulation/lxd/files/lxd.initd b/app-emulation/lxd/files/lxd.initd
new file mode 100644
index 000000000000..b1fa7caac546
--- /dev/null
+++ b/app-emulation/lxd/files/lxd.initd
@@ -0,0 +1,46 @@
+#!/sbin/openrc-run
+# Copyright 1999-2017 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+
+DAEMON=/usr/sbin/lxd
+PIDFILE=/run/lxd.pid
+
+extra_commands="stopall"
+
+depend() {
+ need net
+ use lxcfs
+}
+
+start() {
+ ebegin "Starting lxd service"
+
+ start-stop-daemon --start \
+ --pidfile ${PIDFILE} \
+ --exec ${DAEMON} \
+ --background \
+ --make-pidfile \
+ -- \
+ ${LXD_OPTIONS}
+
+ eend $?
+}
+
+stop() {
+ if [ "$RC_GOINGDOWN" = "YES" ] || [ "$RC_REBOOT" = "YES" ]; then
+ stopall
+ else
+ ebegin "Stopping lxd service (but not containers)"
+ start-stop-daemon --stop --quiet -R TERM/45 -p ${PIDFILE}
+ eend $?
+ fi
+}
+
+stopall() {
+ ebegin "Stopping lxd service and containers"
+ if "${DAEMON}" shutdown; then
+ /etc/init.d/lxd zap
+ rm -f ${PIDFILE}
+ fi
+ eend $?
+}
diff --git a/app-emulation/lxd/files/lxd.service b/app-emulation/lxd/files/lxd.service
new file mode 100644
index 000000000000..d00635fbcdd9
--- /dev/null
+++ b/app-emulation/lxd/files/lxd.service
@@ -0,0 +1,10 @@
+[Unit]
+Description=Container hypervisor based on LXC
+
+[Service]
+ExecStart=/usr/sbin/lxd --group lxd
+KillMode=process
+Restart=on-failure
+
+[Install]
+WantedBy=multi-user.target