From ccd9952ba8b029f506b785d3d2a7ddb3d6782763 Mon Sep 17 00:00:00 2001 From: pvizeli Date: Wed, 22 Mar 2017 12:41:19 +0100 Subject: [PATCH] Minor change --- build-scripts/resinos-build/create_resinos.sh | 3 ++- .../classes/resin-connectable-service.bbclass | 16 ---------------- meta-hassio/conf/distro/hassio.conf | 6 ------ .../recipes-core/dropbear/dropbear_%.bbappend | 5 +++++ 4 files changed, 7 insertions(+), 23 deletions(-) delete mode 100644 meta-hassio/classes/resin-connectable-service.bbclass delete mode 100644 meta-hassio/conf/distro/hassio.conf diff --git a/build-scripts/resinos-build/create_resinos.sh b/build-scripts/resinos-build/create_resinos.sh index 8c3603784..ca0667412 100755 --- a/build-scripts/resinos-build/create_resinos.sh +++ b/build-scripts/resinos-build/create_resinos.sh @@ -96,7 +96,8 @@ docker run --rm \ --machine "$MACHINE" \ ${BARYS_ARGUMENTS_VAR} \ --shared-downloads /yocto/shared-downloads \ - --shared-sstate /yocto/shared-sstate + --shared-sstate /yocto/shared-sstate \ + --resinio # Write deploy artifacts BUILD_DEPLOY_DIR=$WORKSPACE/deploy diff --git a/meta-hassio/classes/resin-connectable-service.bbclass b/meta-hassio/classes/resin-connectable-service.bbclass deleted file mode 100644 index d5798afb4..000000000 --- a/meta-hassio/classes/resin-connectable-service.bbclass +++ /dev/null @@ -1,16 +0,0 @@ -# resin-connectable-service bbclass -# -# Author: Andrei Gherzan - -python __anonymous() { - # Enable/disable systemd services listed in RESIN_CONNECTABLE_SERVICES based on - # RESIN_CONNECTABLE_ENABLE_SERVICES - - pn = d.getVar('PN', True) - services = d.getVar('RESIN_CONNECTABLE_SERVICES', True).split() - - if pn in services: - d.setVar('SYSTEMD_AUTO_ENABLE', 'enable') - -} -systemd_populate_packages[vardeps] += "RESIN_CONNECTABLE_ENABLE_SERVICES" diff --git a/meta-hassio/conf/distro/hassio.conf b/meta-hassio/conf/distro/hassio.conf deleted file mode 100644 index 14fb04380..000000000 --- a/meta-hassio/conf/distro/hassio.conf +++ /dev/null @@ -1,6 +0,0 @@ -# Add hassio flavor -require conf/distro/include/resin-os.inc - -PREFERRED_PROVIDER_docker-disk = "docker-resin-supervisor-disk" -RESIN_CONNECTABLE_SERVICES_remove = "openvpn" -DISTRO_FEATURES_remove = "development-image" diff --git a/meta-hassio/recipes-core/dropbear/dropbear_%.bbappend b/meta-hassio/recipes-core/dropbear/dropbear_%.bbappend index 7a97dd161..749c586c2 100644 --- a/meta-hassio/recipes-core/dropbear/dropbear_%.bbappend +++ b/meta-hassio/recipes-core/dropbear/dropbear_%.bbappend @@ -19,6 +19,11 @@ do_install_append() { install -d ${D}${bindir} install -m 0755 ${WORKDIR}/sync-authorized-keys.sh ${D}${bindir} + if [ "${RESIN_CONNECTABLE_ENABLE_SERVICES}" = "1" ]; then + rm -r ${D}${localstatedir}/lib/dropbear/ + rm ${D}/home/root/.ssh/authorized_keys + fi + if ${@bb.utils.contains('DISTRO_FEATURES','systemd','true','false',d)}; then install -d ${D}${systemd_unitdir}/system install -c -m 0644 ${WORKDIR}/sync-authorized-keys.service ${D}${systemd_unitdir}/system