git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Junio C Hamano <gitster@pobox.com>
To: Karthik Nayak <karthik.188@gmail.com>
Cc: ps@pks.im,  git@vger.kernel.org,  peff@peff.net
Subject: Re: [PATCH] ci/github: add missing 'CI_JOB_IMAGE' env variable
Date: Fri, 21 Mar 2025 00:51:45 -0700	[thread overview]
Message-ID: <xmqqsen6vn1q.fsf@gitster.g> (raw)
In-Reply-To: <20250319163328.525284-1-karthik.188@gmail.com> (Karthik Nayak's message of "Wed, 19 Mar 2025 17:33:28 +0100")

Karthik Nayak <karthik.188@gmail.com> writes:

> The CI setups of GitLab and GitHub use a common dependency management
> script 'ci/install-dependencies.sh'. The script install the necessary
> packages based on a combination of the "$distro" and "$jobname" env
> variables.

It seems that CI_JOB_IMAGE is a GitLab invention that is defined
automatically for all CI/CD jobs?

The range of values for the variable seems to be names of Docker
images, so presumably they mean the same thing when used in GitHub
Actions environment?  I am just idly wondering if ci/*.sh scripts
running in GitLab CI/CD says "Ah, we are using ubuntu-latest image"
and does one thing, if it is always safe and sensible to do the same
thing in GitHub Actions environment when CI_JOB_IMAGE is set to the
same 'ubuntu-latest' value in this workflows/main.yml file for the
job (otherwise our desire to share as much as possible becomes
harder to achieve).

> The "$distro" variable is derived from the "CI_JOB_IMAGE" env variable
> set by the CI configs. In the GitHub CI config, some of the jobs are
> missing this variable. For the 'Documentation' job which depends on
> 'meson' being installed, this raises an error since the 'meson'
> dependency is never installed.
>
> Fix this by adding the 'CI_JOB_IMAGE' variable to all missing jobs. We
> don't add it the windows jobs, since they manager their dependency as
> part of the CI config and no further dependency management is needed.
>
> Signed-off-by: Karthik Nayak <karthik.188@gmail.com>
> ---
>
> Junio, not sure if you wanted a patch here, since you already had a fix
> yourself. But I'm providing one nonetheless, feel free to drop it.

Good.  The one I did was an attempt to blindly sweep the issue under
the rug by patching merely one thing, and I consider that this patch
is the true fix for the root issue, so the other one can be reverted
out of 'next' (or removed from 'next' when it is rebuilt).

Thanks, will queue.

  parent reply	other threads:[~2025-03-21  7:51 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-14 17:36 What's cooking in git.git (Mar 2025, #04; Fri, 14) Junio C Hamano
2025-03-14 18:41 ` Jeff King
2025-03-14 18:42   ` Jeff King
2025-03-15  0:02   ` Junio C Hamano
2025-03-18 15:57     ` [PATCH] install meson for Documentation job Junio C Hamano
2025-03-18 16:19       ` Karthik Nayak
2025-03-18 20:40         ` Junio C Hamano
2025-03-19  9:24           ` Patrick Steinhardt
2025-03-19 16:22             ` Karthik Nayak
2025-03-19 16:33             ` [PATCH] ci/github: add missing 'CI_JOB_IMAGE' env variable Karthik Nayak
2025-03-20  7:10               ` Patrick Steinhardt
2025-03-21  7:51               ` Junio C Hamano [this message]
2025-03-20 20:27             ` [PATCH] install meson for Documentation job Junio C Hamano
2025-03-15  0:32 ` en/diff-rename-follow-fix (Was: Re: What's cooking in git.git (Mar 2025, #04; Fri, 14)) Elijah Newren
2025-03-15  1:22   ` en/diff-rename-follow-fix Junio C Hamano

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=xmqqsen6vn1q.fsf@gitster.g \
    --to=gitster@pobox.com \
    --cc=git@vger.kernel.org \
    --cc=karthik.188@gmail.com \
    --cc=peff@peff.net \
    --cc=ps@pks.im \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).