summaryrefslogtreecommitdiffstats
path: root/meta-agl-ic-container/recipes-platform/images/agl-lxc-autostart.inc
diff options
context:
space:
mode:
Diffstat (limited to 'meta-agl-ic-container/recipes-platform/images/agl-lxc-autostart.inc')
-rw-r--r--meta-agl-ic-container/recipes-platform/images/agl-lxc-autostart.inc19
1 files changed, 19 insertions, 0 deletions
diff --git a/meta-agl-ic-container/recipes-platform/images/agl-lxc-autostart.inc b/meta-agl-ic-container/recipes-platform/images/agl-lxc-autostart.inc
new file mode 100644
index 00000000..41a925e3
--- /dev/null
+++ b/meta-agl-ic-container/recipes-platform/images/agl-lxc-autostart.inc
@@ -0,0 +1,19 @@
+# Integration type support for lxc autostart based startup.
+
+IMAGE_INSTALL += " \
+ ${LXC_CONTAINER_CONFIGS} \
+ lxc-autostart \
+"
+
+LXC_CONTAINER_CONFIGS ?= ""
+
+python __anonymous() {
+ for c in (d.getVar('CONTAINER_IMAGES') or "").split():
+ (mc, image) = c.split(':')
+
+ # Assume there is a X-lxc-config package for guest-image-X
+ config = image
+ if config.startswith('guest-image-'):
+ config = config[len('guest-image-'):]
+ d.appendVar('LXC_CONTAINER_CONFIGS', ' ' + 'lxc-config-' + config)
+}