summaryrefslogtreecommitdiffstats
path: root/recipes-extended/builder-container-config/builder-container-config_1.0.bb
blob: 6b023caa56b63f84e7f2e1e0619f6c4a8ce28f31 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
SUMMARY = "Entrypoint and user configuration for Yocto builder container"
DESCRIPTION = "CROPS-style entrypoint script that creates a builder user \
    matching the /workdir mount owner, then hands off to systemd."
LICENSE = "MIT"
LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/MIT;md5=0835ade698e0bcf8506ecda2f7b4f302"

SRC_URI = "file://builder-entry.sh"

S = "${UNPACKDIR}"
RDEPENDS:${PN} = "bash sudo shadow"

inherit allarch

do_install() {
    # Entrypoint script (CROPS-style user creation -> exec /sbin/init)
    install -d ${D}${bindir}
    install -m 0755 ${UNPACKDIR}/builder-entry.sh ${D}${bindir}/

    # Create /workdir mount point
    install -d ${D}/workdir
}

FILES:${PN} = "${bindir}/builder-entry.sh /workdir"