From 71fbe1fd89e2869dbcad20f1b1c4fbaba4338f15 Mon Sep 17 00:00:00 2001 From: Laurent Bonnans Date: Mon, 22 Jul 2019 17:42:13 +0200 Subject: Output site.conf during CI configure step Signed-off-by: Laurent Bonnans --- scripts/ci/configure.sh | 3 +++ 1 file changed, 3 insertions(+) (limited to 'scripts') diff --git a/scripts/ci/configure.sh b/scripts/ci/configure.sh index a8968da..67563ed 100755 --- a/scripts/ci/configure.sh +++ b/scripts/ci/configure.sh @@ -69,3 +69,6 @@ SSTATE_DIR = "$SSTATE_DIR" DL_DIR = "$DL_DIR" EOF fi + +echo -e ">> Final configuration (site.conf):\n" +cat "$SITE_CONF" -- cgit v1.2.3-54-g00ecf From 5d868c995da18f865e2ad852ff8ea27cf404ce84 Mon Sep 17 00:00:00 2001 From: Laurent Bonnans Date: Tue, 23 Jul 2019 09:55:29 +0200 Subject: Fix issue with gitlab and Docker 19 (use docker 18) See https://gitlab.com/gitlab-org/gitlab-runner/issues/4499 Signed-off-by: Laurent Bonnans --- scripts/ci/gitlab/docker.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'scripts') diff --git a/scripts/ci/gitlab/docker.yml b/scripts/ci/gitlab/docker.yml index 827bb47..5b81d77 100644 --- a/scripts/ci/gitlab/docker.yml +++ b/scripts/ci/gitlab/docker.yml @@ -6,10 +6,10 @@ # - BITBAKE_CHECKOUT_IMAGE # - BITBKAE_IMAGE_MASTER # - BITBAKE_CHECKOUT_IMAGE_MASTER - image: docker:stable + image: docker:18 stage: docker services: - - docker:dind + - docker:18-dind before_script: - docker login -u gitlab-ci-token -p "$CI_JOB_TOKEN" "$CI_REGISTRY" script: @@ -26,10 +26,10 @@ # parameters: # - BITBAKE_IMAGE # - BITBAKE_CHECKOUT_IMAGE - image: docker:stable + image: docker:18 stage: docker services: - - docker:dind + - docker:18-dind before_script: - docker login -u gitlab-ci-token -p "$CI_JOB_TOKEN" "$CI_REGISTRY" script: -- cgit v1.2.3-54-g00ecf From 82308b9f8f1509d77330e70e162a1b066ad85e34 Mon Sep 17 00:00:00 2001 From: Laurent Bonnans Date: Tue, 23 Jul 2019 11:15:51 +0200 Subject: Remove Jenkins references in meta-updater Was killed for good Signed-off-by: Laurent Bonnans --- scripts/ci/Jenkinsfile.bleeding | 87 ------------------------------ scripts/ci/Jenkinsfile.bleeding-selftest | 91 -------------------------------- scripts/ci/README.adoc | 14 ----- 3 files changed, 192 deletions(-) delete mode 100644 scripts/ci/Jenkinsfile.bleeding delete mode 100644 scripts/ci/Jenkinsfile.bleeding-selftest delete mode 100644 scripts/ci/README.adoc (limited to 'scripts') diff --git a/scripts/ci/Jenkinsfile.bleeding b/scripts/ci/Jenkinsfile.bleeding deleted file mode 100644 index 6d340fd..0000000 --- a/scripts/ci/Jenkinsfile.bleeding +++ /dev/null @@ -1,87 +0,0 @@ -// This CI setup checks out aktualizr, meta-updater and updater-repo and builds -// master branches whenever a change is pushed to any of these - -// define these for docker image creation -node { - // might cause some problems: - // https://stackoverflow.com/questions/44805076/setting-build-args-for-dockerfile-agent-using-a-jenkins-declarative-pipeline - JENKINS_UID = sh(returnStdout: true, script: 'id -u').trim() - JENKINS_GID = sh(returnStdout: true, script: 'id -g').trim() -} - -pipeline { - agent any - environment { - TEST_AKTUALIZR_REMOTE = 'aktualizr' - TEST_AKTUALIZR_DIR = 'aktualizr' - TEST_AKTUALIZR_BRANCH = 'master' - TEST_BITBAKE_COMMON_DIR = "/opt/jenkins/bitbake-common" - } - stages { - stage('checkout') { - steps { - - checkout([$class: 'GitSCM', - userRemoteConfigs: [ - [url: 'https://github.com/advancedtelematic/aktualizr', name: 'aktualizr'] - ], - branches: [[name: 'refs/heads/master']], - extensions: [ - [$class: 'DisableRemotePoll'], - [$class: 'PruneStaleBranch'], - [$class: 'RelativeTargetDirectory', - relativeTargetDir: 'aktualizr' - ] - ], - ]) - - checkout([$class: 'RepoScm', - manifestRepositoryUrl: 'https://github.com/advancedtelematic/updater-repo', - manifestBranch: null, - manifestFile: 'master.xml', - manifestGroup: null, - mirrorDir: null, - jobs: 0, - depth: 0, - localManifest: null, - destinationDir: 'updater-repo', - repoUrl: null, - currentBranch: false, - resetFirst: true, - quiet: false, - trace: false, - showAllChanges: false, - ]) - - // ignore bitbake build directories in docker - sh 'echo \'build*\' > .dockerignore' - - // override meta-updater commit with currently tested branch - sh ''' - META_UPDATER_COMMIT=$(git rev-parse HEAD) - cd updater-repo/meta-updater - git checkout $META_UPDATER_COMMIT - ''' - } - } - stage('build-core-image-minimal') { - agent { - dockerfile { - filename 'scripts/ci/Dockerfile.bitbake' - args '-v /opt/jenkins/bitbake-common:/opt/jenkins/bitbake-common' - additionalBuildArgs "--build-arg uid=${JENKINS_UID} --build-arg gid=${JENKINS_GID}" - reuseNode true - } - } - environment { - TEST_AKTUALIZR_CREDENTIALS = credentials('garage-credentials') - } - steps { - sh 'scripts/ci/configure.sh' - - sh 'scripts/ci/build.sh core-image-minimal' - } - } - } -} -// vim: set ft=groovy tabstop=2 shiftwidth=2 expandtab: diff --git a/scripts/ci/Jenkinsfile.bleeding-selftest b/scripts/ci/Jenkinsfile.bleeding-selftest deleted file mode 100644 index 8c2d1de..0000000 --- a/scripts/ci/Jenkinsfile.bleeding-selftest +++ /dev/null @@ -1,91 +0,0 @@ -// This CI setup checks out aktualizr, meta-updater and updater-repo and builds -// master branches whenever a change is pushed to any of these - -// define these for docker image creation -node { - // might cause some problems: - // https://stackoverflow.com/questions/44805076/setting-build-args-for-dockerfile-agent-using-a-jenkins-declarative-pipeline - JENKINS_UID = sh(returnStdout: true, script: 'id -u').trim() - JENKINS_GID = sh(returnStdout: true, script: 'id -g').trim() -} - -pipeline { - agent { - node { label 'bitbake' } - } - environment { - TEST_AKTUALIZR_REMOTE = 'aktualizr' - TEST_AKTUALIZR_DIR = 'aktualizr' - TEST_AKTUALIZR_BRANCH = 'master' - TEST_BITBAKE_COMMON_DIR = "/opt/jenkins/bitbake-common" - } - stages { - stage('checkout') { - steps { - - checkout([$class: 'GitSCM', - userRemoteConfigs: [ - [url: 'https://github.com/advancedtelematic/aktualizr', name: 'aktualizr'] - ], - branches: [[name: 'refs/heads/master']], - extensions: [ - [$class: 'DisableRemotePoll'], - [$class: 'PruneStaleBranch'], - [$class: 'RelativeTargetDirectory', - relativeTargetDir: 'aktualizr' - ] - ], - ]) - - checkout([$class: 'RepoScm', - manifestRepositoryUrl: 'https://github.com/advancedtelematic/updater-repo', - manifestBranch: null, - manifestFile: 'master.xml', - manifestGroup: null, - mirrorDir: null, - jobs: 0, - depth: 0, - localManifest: null, - destinationDir: 'updater-repo', - repoUrl: null, - currentBranch: false, - resetFirst: true, - quiet: false, - trace: false, - showAllChanges: false, - ]) - - // ignore bitbake build directories in docker - sh 'echo \'build*\' > .dockerignore' - - // override meta-updater commit with currently tested branch - sh ''' - META_UPDATER_COMMIT=$(git rev-parse HEAD) - cd updater-repo/meta-updater - git checkout $META_UPDATER_COMMIT - ''' - } - } - stage('build-core-image-minimal+oe-selftest') { - agent { - dockerfile { - filename 'scripts/ci/Dockerfile.bitbake' - args '-v /opt/jenkins/bitbake-common:/opt/jenkins/bitbake-common' - additionalBuildArgs "--build-arg uid=${JENKINS_UID} --build-arg gid=${JENKINS_GID}" - reuseNode true - } - } - environment { - TEST_AKTUALIZR_CREDENTIALS = credentials('garage-credentials') - } - steps { - sh 'scripts/ci/configure.sh' - - sh 'scripts/ci/build.sh core-image-minimal' - - sh 'scripts/ci/oe-selftest.sh' - } - } - } -} -// vim: set ft=groovy tabstop=2 shiftwidth=2 expandtab: diff --git a/scripts/ci/README.adoc b/scripts/ci/README.adoc deleted file mode 100644 index 222982b..0000000 --- a/scripts/ci/README.adoc +++ /dev/null @@ -1,14 +0,0 @@ -= Jenkins setup for running meta-updater CI - -As bitbake is quite resource-hungry, there are some special steps that are -needed to run Jenkins CI tasks: - -- docker should be installed and the `jenkins` unix user should belong to - the `docker` group -- `/opt/jenkins` should exist and have `jenkins:jenkins` permissions, it - will be mapped as a volume on the same location in the docker build - container - -Note that for nodes running Jenkins slaves as a docker container, the -`/opt/jenkins` directory must exist on the host system as well, with -permissions matching the user and groupd ids in Jenkins' docker -- cgit v1.2.3-54-g00ecf