From patchwork Wed Sep 11 06:46:40 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Alex_Benn=C3=A9e?= X-Patchwork-Id: 827363 Delivered-To: patch@linaro.org Received: by 2002:adf:ab1c:0:b0:367:895a:4699 with SMTP id q28csp657418wrc; Tue, 10 Sep 2024 23:48:44 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCUBjKqNnvnJePRmmTzpX+8migroHz1V5piNAdmsqExUhFWUKKsEMyarkgY1A8YB9hnDuR+R+Q==@linaro.org X-Google-Smtp-Source: AGHT+IE1lXVnByomnl9Pd7iefRfpiBn5iUFgHEzfU/i0GoRj68e7t1cmZn/Z59b0CVyPdhARSkS1 X-Received: by 2002:a05:620a:2449:b0:7a9:aba6:d012 with SMTP id af79cd13be357-7a9aba6d431mr1721712585a.22.1726037324055; Tue, 10 Sep 2024 23:48:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1726037324; cv=none; d=google.com; s=arc-20240605; b=kRvK79BNwDmqW4qfcKanor/aJgWZwZcq9gKXHcG1QayNaIJ0xQ/dPPUaxOWfy1kuQF D5KSCsQAC2+JTf/qFAc7jk7hvANDO+uS1zm1mVhl8YQ59xcPj+nNqsQq+Q0IXAmocbEj 7C548VPCuWQo3epQ99IS7+/RTOcdvyjOU7GT/rg7PPSOejLYZuFDWAKlUVlPh2pear2E H5C4tNi+trKiCF/EGbM4D/Rem5UWXMcZE2AkydcvZeOobD5BVF1G6T2eiEes/pkNmsUI E2TmXigLnV06kpYzNQxl17LBD+Li3EGYZPkBRh+qMfUvzTUn3Bttci0WdHc6+AepKP3b nVbQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=FrvaAWuF5v0aOpUmK/2t60ZFaqLxvEHy+/W3U6nvVig=; fh=+k0tS9PoAeXIWl6E54cI11Z4akDF1oca09oqG468MiA=; b=c2biDIKru4OiZ8HZRZuvsbQvJUB2d1zMJmyg+TlpY6whRd4TnTLVxf6xrXSREvgLTZ 5N7eWYfLhdX3KMZ6jWOX1Eg1A0BZmgfVKRKwvZT/0dfzReIpbJzHLj6y/3jyTDOObxed TylpcNu+jJDHhgGR7IojARpIxlEu1PkbcjMqBBQBhWhgNhh8Zj6o0zyWUjyuwtn19cay mfwOHzqhgE/PKKaQV4ss7iIM0WXOpPvkvBoXTMPuFzP1FX1kb7D8uznRiQmyNd4RXkGQ TcQACqEh8tUBYdqe8t+TN0HGxDUTVenbHEjPxuH+uhc7XhXX0TqzcQAtZvB0yKegrgga 1K5w==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="OaPdf/ja"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Return-Path: Received: from lists.gnu.org (lists.gnu.org. [209.51.188.17]) by mx.google.com with ESMTPS id af79cd13be357-7a9a79f046asi947697685a.219.2024.09.10.23.48.43 for (version=TLS1_2 cipher=ECDHE-ECDSA-CHACHA20-POLY1305 bits=256/256); Tue, 10 Sep 2024 23:48:44 -0700 (PDT) Received-SPF: pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) client-ip=209.51.188.17; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b="OaPdf/ja"; spf=pass (google.com: domain of qemu-devel-bounces+patch=linaro.org@nongnu.org designates 209.51.188.17 as permitted sender) smtp.mailfrom="qemu-devel-bounces+patch=linaro.org@nongnu.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org; dara=neutral header.i=@linaro.org Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1soH7x-0000dq-7q; Wed, 11 Sep 2024 02:46:57 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1soH7v-0000YO-P7 for qemu-devel@nongnu.org; Wed, 11 Sep 2024 02:46:55 -0400 Received: from mail-ej1-x635.google.com ([2a00:1450:4864:20::635]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1soH7s-0004Pa-Kr for qemu-devel@nongnu.org; Wed, 11 Sep 2024 02:46:55 -0400 Received: by mail-ej1-x635.google.com with SMTP id a640c23a62f3a-a8a6d1766a7so195148966b.3 for ; Tue, 10 Sep 2024 23:46:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1726037211; x=1726642011; darn=nongnu.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=FrvaAWuF5v0aOpUmK/2t60ZFaqLxvEHy+/W3U6nvVig=; b=OaPdf/jaOMfpBc0FPBwpZksFFTXAkca4U6xVZcoeMexnrE4H+yUIoAORtuOelWqFvw fx550NHLepfQUL+zwCtiREpS8rBrwHwvww7jf52ufpEFRizjur1xbYp/3zLkXrfAfuwb HmIr31/X2efZUB0Pr8i3sUi9sRDsIXs+2Ade0+8DfqNAdiMnepnqUT9+d4a9KNaTPoev CugY4TEPcZie+cVYLtuQfN9vjyr6XWm2/Yeh/3UJxG+II9Prx+ZUaBZui0OQhNzBGFnr xdKr1/idBOZ8AEDiu/ZdP7+/QsYlsINT/wCDB1Ej76RT0scXtHn4pdEBs6pJPDx34j70 OLig== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1726037211; x=1726642011; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=FrvaAWuF5v0aOpUmK/2t60ZFaqLxvEHy+/W3U6nvVig=; b=DP0R1qtazcp5Uvcsap0QWxGx95YofztxinOoED2zoivVEQCZhJ4FgMWUHcst+70E9W PgMgbXQy48r2WPRucBGelIXJTFd2j+MsXGMuWHUGmmxrRfLX/WssK1wf6r326wT5upzD gqRK2i8YnQz09I+HK0C5QvK169kqoiRImbTgRWfZFDIXsVxeNL5ysm/ONKnSHNgmiUWZ 2CslIleR0m6r0TAOUByUJGotIlWKyJ3xqaQNDAFuWlFyJUhkgqYjhZ9NZ9Sfpk+XxJl3 unF0kBN7WpW/Y9o+p/LzIHvigJIyMHR6Bv/9GiiDCT8EtX2KvrpdGFkvXh9Ghv6qLORB gkxA== X-Gm-Message-State: AOJu0Yx/8Id6R5Q0EtGHoFUN7LVKihHisk84D9iRnPmNavvYe57cJ5Yz tT/qeL3NjnXWSOicIjvlEzuRGTdisTdOIs+ogZrltJdshno3Z58gDqTjDGc+eE0= X-Received: by 2002:a17:907:86a1:b0:a8a:83e9:43e2 with SMTP id a640c23a62f3a-a90047457e7mr183129466b.12.1726037210948; Tue, 10 Sep 2024 23:46:50 -0700 (PDT) Received: from draig.lan ([85.9.250.243]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a9012fa463csm19801366b.139.2024.09.10.23.46.48 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 10 Sep 2024 23:46:48 -0700 (PDT) Received: from draig.lan (localhost [IPv6:::1]) by draig.lan (Postfix) with ESMTP id 802E05FA0E; Wed, 11 Sep 2024 07:46:46 +0100 (BST) From: =?utf-8?q?Alex_Benn=C3=A9e?= To: qemu-devel@nongnu.org Cc: =?utf-8?q?Alex_Benn=C3=A9e?= , Pierrick Bouvier , =?utf-8?q?Philippe_Mathieu-?= =?utf-8?q?Daud=C3=A9?= , Thomas Huth , Wainer dos Santos Moschetta , Beraldo Leal Subject: [PULL 05/10] scripts/ci: update the gitlab-runner playbook Date: Wed, 11 Sep 2024 07:46:40 +0100 Message-Id: <20240911064645.357592-6-alex.bennee@linaro.org> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20240911064645.357592-1-alex.bennee@linaro.org> References: <20240911064645.357592-1-alex.bennee@linaro.org> MIME-Version: 1.0 Received-SPF: pass client-ip=2a00:1450:4864:20::635; envelope-from=alex.bennee@linaro.org; helo=mail-ej1-x635.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+patch=linaro.org@nongnu.org Sender: qemu-devel-bounces+patch=linaro.org@nongnu.org The upstream install instructions: https://docs.gitlab.com/runner/install/linux-repository.html Now refer to repositories and a setup script. Modernise the playbook to use the preferred delivery method. Reviewed-by: Pierrick Bouvier Signed-off-by: Alex Bennée Message-Id: <20240910173900.4154726-6-alex.bennee@linaro.org> diff --git a/scripts/ci/setup/gitlab-runner.yml b/scripts/ci/setup/gitlab-runner.yml index 7bdafab511..57e7faebf1 100644 --- a/scripts/ci/setup/gitlab-runner.yml +++ b/scripts/ci/setup/gitlab-runner.yml @@ -49,30 +49,51 @@ - debug: msg: gitlab-runner arch is {{ gitlab_runner_arch }} - - name: Download the matching gitlab-runner (DEB) + # Debian/Ubuntu setup + - name: Get gitlab-runner repo setup script (DEB) get_url: dest: "/root/" - url: "https://gitlab-runner-downloads.s3.amazonaws.com/latest/deb/gitlab-runner_{{ gitlab_runner_arch }}.deb" + url: "https://packages.gitlab.com/install/repositories/runner/gitlab-runner/script.deb.sh" + mode: 0755 when: - ansible_facts['distribution'] == 'Ubuntu' - - name: Download the matching gitlab-runner (RPM) + - name: Run gitlab-runner repo setup script (DEB) + shell: "/root/script.deb.sh" + when: + - ansible_facts['distribution'] == 'Ubuntu' + + - name: Install gitlab-runner (DEB) + ansible.builtin.apt: + name: gitlab-runner + update_cache: yes + state: present + when: + - ansible_facts['distribution'] == 'Ubuntu' + + # RPM setup + - name: Get gitlab-runner repo setup script (RPM) get_url: dest: "/root/" - url: "https://gitlab-runner-downloads.s3.amazonaws.com/latest/rpm/gitlab-runner_{{ gitlab_runner_arch }}.rpm" + url: "https://packages.gitlab.com/install/repositories/runner/gitlab-runner/script.rpm.sh" + mode: 0755 when: - ansible_facts['distribution'] == 'CentOS' - - name: Install gitlab-runner via package manager (DEB) - apt: deb="/root/gitlab-runner_{{ gitlab_runner_arch }}.deb" + - name: Run gitlab-runner repo setup script (RPM) + shell: "/root/script.rpm.sh" when: - - ansible_facts['distribution'] == 'Ubuntu' + - ansible_facts['distribution'] == 'CentOS' - - name: Install gitlab-runner via package manager (RPM) - yum: name="/root/gitlab-runner_{{ gitlab_runner_arch }}.rpm" + - name: Install gitlab-runner (RPM) + yum: + name: gitlab-runner + update_cache: yes + state: present when: - ansible_facts['distribution'] == 'CentOS' + # Register Runners - name: Register the gitlab-runner command: "/usr/bin/gitlab-runner register --non-interactive --url {{ gitlab_runner_server_url }} --registration-token {{ gitlab_runner_registration_token }} --executor shell --tag-list {{ ansible_facts[\"architecture\"] }},{{ ansible_facts[\"distribution\"]|lower }}_{{ ansible_facts[\"distribution_version\"] }} --description '{{ ansible_facts[\"distribution\"] }} {{ ansible_facts[\"distribution_version\"] }} {{ ansible_facts[\"architecture\"] }} ({{ ansible_facts[\"os_family\"] }})'"