diff options
Diffstat (limited to 'scripts/ci/configure.sh')
-rwxr-xr-x | scripts/ci/configure.sh | 25 |
1 files changed, 23 insertions, 2 deletions
diff --git a/scripts/ci/configure.sh b/scripts/ci/configure.sh index cf42825..1e87a7b 100755 --- a/scripts/ci/configure.sh +++ b/scripts/ci/configure.sh | |||
@@ -9,7 +9,8 @@ TEST_REPO_DIR=${TEST_REPO_DIR:-updater-repo} | |||
9 | 9 | ||
10 | TEST_AKTUALIZR_DIR=${TEST_AKTUALIZR_DIR:-.} | 10 | TEST_AKTUALIZR_DIR=${TEST_AKTUALIZR_DIR:-.} |
11 | TEST_AKTUALIZR_BRANCH=${TEST_AKTUALIZR_BRANCH:-master} | 11 | TEST_AKTUALIZR_BRANCH=${TEST_AKTUALIZR_BRANCH:-master} |
12 | TEST_AKTUALIZR_REV=${TEST_AKTUALIZR_REV:-$(GIT_DIR="${TEST_AKTUALIZR_DIR}/.git" git rev-parse "${TEST_AKTUALIZR_BRANCH}")} | 12 | TEST_AKTUALIZR_REV=${TEST_AKTUALIZR_REV:-$(GIT_DIR="$TEST_AKTUALIZR_DIR/.git" git rev-parse "$TEST_AKTUALIZR_REMOTE/$TEST_AKTUALIZR_BRANCH")} |
13 | TEST_BITBAKE_COMMON_DIR=${TEST_BITBAKE_COMMON_DIR:-} | ||
13 | 14 | ||
14 | # move existing conf directory to backup, before generating a new one | 15 | # move existing conf directory to backup, before generating a new one |
15 | rm -rf "${TEST_BUILD_DIR}/conf.old" || true | 16 | rm -rf "${TEST_BUILD_DIR}/conf.old" || true |
@@ -22,12 +23,32 @@ echo ">> Running envsetup.sh" | |||
22 | . "${TEST_REPO_DIR}/meta-updater/scripts/envsetup.sh" "${TEST_MACHINE}" "${TEST_BUILD_DIR}" | 23 | . "${TEST_REPO_DIR}/meta-updater/scripts/envsetup.sh" "${TEST_MACHINE}" "${TEST_BUILD_DIR}" |
23 | ) | 24 | ) |
24 | 25 | ||
25 | echo ">> Set aktualizr branch in bitbake's config" | 26 | set +x |
26 | 27 | ||
28 | echo ">> Set common bitbake config options" | ||
27 | cat << EOF > "${TEST_BUILD_DIR}/conf/site.conf" | 29 | cat << EOF > "${TEST_BUILD_DIR}/conf/site.conf" |
28 | SANITY_TESTED_DISTROS = "" | 30 | SANITY_TESTED_DISTROS = "" |
31 | SSTATE_MIRRORS ?= "file://.* https://bitbake-cache.atsgarage.com/PATH;downloadfilename=PATH" | ||
32 | IMAGE_FEATURES += "ssh-server-openssh" | ||
33 | |||
34 | EOF | ||
35 | |||
36 | echo ">> Set aktualizr branch in bitbake's config" | ||
37 | cat << EOF >> "${TEST_BUILD_DIR}/conf/site.conf" | ||
29 | SRCREV_pn-aktualizr = "$TEST_AKTUALIZR_REV" | 38 | SRCREV_pn-aktualizr = "$TEST_AKTUALIZR_REV" |
30 | SRCREV_pn-aktualizr-native = "\${SRCREV_pn-aktualizr}" | 39 | SRCREV_pn-aktualizr-native = "\${SRCREV_pn-aktualizr}" |
31 | BRANCH_pn-aktualizr = "$TEST_AKTUALIZR_BRANCH" | 40 | BRANCH_pn-aktualizr = "$TEST_AKTUALIZR_BRANCH" |
32 | BRANCH_pn-aktualizr-native = "\${BRANCH_pn-aktualizr}" | 41 | BRANCH_pn-aktualizr-native = "\${BRANCH_pn-aktualizr}" |
42 | |||
43 | EOF | ||
44 | |||
45 | if [[ -n $TEST_BITBAKE_COMMON_DIR ]]; then | ||
46 | echo ">> Set caching" | ||
47 | SSTATE_DIR="$TEST_BITBAKE_COMMON_DIR/sstate-cache" | ||
48 | DL_DIR="$TEST_BITBAKE_COMMON_DIR/downloads" | ||
49 | mkdir -p "$SSTATE_DIR" "$DL_DIR" | ||
50 | cat << EOF >> "${TEST_BUILD_DIR}/conf/site.conf" | ||
51 | SSTATE_DIR = "$SSTATE_DIR" | ||
52 | DL_DIR = "$DL_DIR" | ||
33 | EOF | 53 | EOF |
54 | fi | ||