From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from shymkent.ilbers.de ([unix socket]) by shymkent (Cyrus 2.5.10-Debian-2.5.10-3+deb9u2) with LMTPA; Mon, 07 Oct 2024 14:27:44 +0200 X-Sieve: CMU Sieve 2.4 Received: from mail-pj1-f55.google.com (mail-pj1-f55.google.com [209.85.216.55]) by shymkent.ilbers.de (8.15.2/8.15.2/Debian-8+deb9u1) with ESMTPS id 497CRhNA016293 (version=TLSv1.2 cipher=ECDHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT) for ; Mon, 7 Oct 2024 14:27:44 +0200 Received: by mail-pj1-f55.google.com with SMTP id 98e67ed59e1d1-2e0853aafcesf5733465a91.1 for ; Mon, 07 Oct 2024 05:27:44 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1728304057; cv=pass; d=google.com; s=arc-20240605; b=P8k8SgyywQYoMbwuVcO0l2QjIATs1v/ASxBJ1uLacU5wsS78WARDOGBpo6COuK44I8 kaAJU48s2kHN0DU4NGsrGqme7XtqC/zK0WeIY+GJWmPu+wNF5HtEwGH0VUUniowXn9AC JHcg62yX2EvFtcn9Qg6sEMXC5J+aYDhqLj6voHAkRcNgEHtmcMD16x4g5dzWlUksH8y6 0T4wArDOQ1QDhpVTId1clumFFiflxOFThjMFJBqLV/z/S0yB0LqaBMDLWSXtvR59RbK5 Rf0nx6pDFtVB/3N7oN+sjirxFVSFJeqmckIVUMaou9C/gfhu/nH10QRJyuwMXborQNHw 3jiA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:feedback-id:mime-version :message-id:date:subject:cc:to:from:dkim-signature; bh=a/jEdEFtKeU5QzXz2VJxJZPUNm6thzr5+CRzwvoLnGA=; fh=CHIRfqOJCj7oqC/W4eJajI5iauNg2283YYDDJJfo/BM=; b=U7vBpV5VNguM2bTNQ5W2h6S1L0J8io4fKKDadByV2TDba2SdsNhcare40mGcd8giXc ngny9pMriGDvQz8eFAN++f6LWDkNFlwb+yWirMfI1vg+cdQdM2Lo1ii8tF6AxUDNnnxK 7ROe/hE6SyeMMfXujyp4RSpw5k0lezdQFJQRCgNXaUZN4Umoni9wvR288ZRaFXwPn58T voj2LBFsLcOf7xaWo6QIhnrRif1gUlZBY00at8Pdhr/iPkfmH8gEr71Bdz5JPZXpFgeW zWot3ClxmujnUTkX4lEk2dqgLD7axseelVwVOe/be6526YNdcH1d3/JcGMdNUgfDJxV6 odUQ==; darn=ilbers.de ARC-Authentication-Results: i=2; gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm2 header.b=CNh0ssTx; spf=pass (google.com: domain of fm-1326448-20241007122733dd046c1202fb51ff1d-p_x6pe@rts-flowmailer.siemens.com designates 185.136.64.228 as permitted sender) smtp.mailfrom=fm-1326448-20241007122733dd046c1202fb51ff1d-p_x6Pe@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1728304057; x=1728908857; darn=ilbers.de; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to :x-original-authentication-results:x-original-sender:feedback-id :mime-version:message-id:date:subject:cc:to:from:from:to:cc:subject :date:message-id:reply-to; bh=a/jEdEFtKeU5QzXz2VJxJZPUNm6thzr5+CRzwvoLnGA=; b=tHQq35ZrYHQVC+9UqGCQ2JwUSOmczgWCjmI09PxDEphDiiumqJe93HGcknrWpCF+/f Dn4VBDngRFViv4o7aGzfy/8KiNpbDSe9BrAT75fiqMYm9SLkyQuy9Jjpi16AJArqkmBi VtKsKhfcaIa+r23YL0b8r6ydmajLN7zXSnp4GJgksnV/g7O6E92gwEbh0ymNhlBWCo8h fOnFr38zmNQUT7lmPsZNHbOQoWVTplpVJoqgVmGVmhUNUN3YGu7XEXMhWBXRTkk20jix oVb64ndWy3QXmJfynS1uwEwjoGxyQNtezeYHVwEnQJJWJlO4Dy/rnfS2OuibmY59nsJr oO1w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728304057; x=1728908857; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-authentication-results:x-original-sender:feedback-id :mime-version:message-id:date:subject:cc:to:from:x-beenthere :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=a/jEdEFtKeU5QzXz2VJxJZPUNm6thzr5+CRzwvoLnGA=; b=ho6xu+IMdPfdeNFxb4KpjSGTqsyqat595pM+vB8OUoCfDm6sOfaCS+Mf6DX79BfN7q r3/iTkmgPmL2eXmBAa9leNh4ukLRX3ynMxrQc4xX4Wcl1PqR4p2Gd/KHwqo8VkKCoBz5 6lxbYQom9C+pgSqRx/YGq4P14qQ/1Bw475qZlVlsDmzBfMKoJ5vOq5nWHBSKEu9PyyE5 TqKV3FYruW080E2QlUobl1Jz1n0FFbzJr3pIUcp9tfRfpjj6A/4bQ/1WhuhrB2PmOVrd hOEgS8rDYe3jnyQHLwGqbogxArss8IZTF7Yu0weik8LGjQ2ratOJYx0omxu+c+xyrjdn qGdg== X-Forwarded-Encrypted: i=2; AJvYcCWoh/ep/GlPn4ATsbio8jH8vM/DwLb2U5B3uBTYnALmMI8WzfzpsA3gLcDbj4Heyoe52Kv1@ilbers.de X-Gm-Message-State: AOJu0YyJkrOtf7Pzw5yS/wBEjr7MhY6S+PIUPvG32mtBEO295DlEaoV3 GiJaPMnTF9zms1bnoY7juAmLYAwpW+0wtce/x1RjQ+sEZTofIdJz X-Google-Smtp-Source: AGHT+IG9v/MGZDsnoL7M/FoDutoxHPz7G6gHnXOF2TjMyZt06YUCqbqIXvSi4zinDKMa6kyxbrv5dg== X-Received: by 2002:a17:90a:f2c4:b0:2e0:9160:1842 with SMTP id 98e67ed59e1d1-2e1e620c8e8mr15761006a91.1.1728304057090; Mon, 07 Oct 2024 05:27:37 -0700 (PDT) X-BeenThere: isar-users@googlegroups.com Received: by 2002:a17:90b:19d8:b0:2da:30b7:69a5 with SMTP id 98e67ed59e1d1-2e1b39cbbf4ls3180658a91.2.-pod-prod-08-us; Mon, 07 Oct 2024 05:27:36 -0700 (PDT) X-Received: by 2002:a17:90a:ce96:b0:2d8:f0e2:96bc with SMTP id 98e67ed59e1d1-2e1e620ce6dmr14197353a91.4.1728304055782; Mon, 07 Oct 2024 05:27:35 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1728304055; cv=none; d=google.com; s=arc-20240605; b=AAssWij8kPyyLJAWkJ+5a/5ETMXPTcUzS1iUzjwL+SWipzRciB9tq2EZMudBqXcInO 4sieMPSKspmaGJwmIbi/YIlHWmE675Xd5MjW15TJPn2Hraq5bFPExKUwL921/fy7tASG dc9iFqhIcDgYgr8xdrx+Ai6z2d0Fp3p0gDQgQqmZ6DG1yxReumR3DOXSzDSNlXoEPmOs w4d1NIm7ghOZKsqY0L0uhaV5ermLG8Bju4b06ZMal8orEUcsM5PRE1IJRMOgnrtlcUIh 7VRt2zNykdEiJIMorA1/VF7f7mU8pGK/Oel8TqBLF9JVulIvMavdjojulUU7KzgmEpPZ f0Rg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20240605; h=feedback-id:content-transfer-encoding:mime-version:message-id:date :subject:cc:to:from:dkim-signature; bh=ezwO+3UkzZmwruKypYbGbac7dMbqSEjnSTeZmuzo6No=; fh=Z5Qnyb0EtJ8UwrxkpbdSYE+xHzQI6qPfwJivtsUki18=; b=ESDx8xJbxxrcwmllX08wK0asiIWNCHuJZkIKtwG5wc4phf7q1UFMqv1dNzq5bQOisE ndCiIbV5WzL9+GRht0GJ/50/7OBAwWjdA1wbXnAIbgT2j+sMwELucBUiwhNaHOrExTDW /ekQW9jEKRnXwznCGky0PhxCdGtt3kocUzvFUaus25L/jJrCwqDFmu2pG9akkKOADPBb 89OJHlrfWfhcAbPRV/aGn/1hmWs/kyp0u0q6dHCnLTXSBDebt/OTwcFgkE6k/WKrE5Hx EzNDLjXyDNZn0eGu0DBiwOVZuxm7FfWCsLimqL1yIq+pgOMMA+4Sf5n5WCf0CyF7ThNQ 5VNw==; dara=google.com ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm2 header.b=CNh0ssTx; spf=pass (google.com: domain of fm-1326448-20241007122733dd046c1202fb51ff1d-p_x6pe@rts-flowmailer.siemens.com designates 185.136.64.228 as permitted sender) smtp.mailfrom=fm-1326448-20241007122733dd046c1202fb51ff1d-p_x6Pe@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com Received: from mta-64-228.siemens.flowmailer.net (mta-64-228.siemens.flowmailer.net. [185.136.64.228]) by gmr-mx.google.com with ESMTPS id 98e67ed59e1d1-2e1e60a0bc3si620474a91.0.2024.10.07.05.27.35 for (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 07 Oct 2024 05:27:35 -0700 (PDT) Received-SPF: pass (google.com: domain of fm-1326448-20241007122733dd046c1202fb51ff1d-p_x6pe@rts-flowmailer.siemens.com designates 185.136.64.228 as permitted sender) client-ip=185.136.64.228; Received: by mta-64-228.siemens.flowmailer.net with ESMTPSA id 20241007122733dd046c1202fb51ff1d for ; Mon, 07 Oct 2024 14:27:33 +0200 From: "alexander.heinisch via isar-users" To: isar-users@googlegroups.com Cc: jan.kiszka@siemens.com, felix.moessbauer@siemens.com, Alexander Heinisch Subject: [PATCH v3] meta: Allow to specify the snapshot date in the upstream format. Date: Mon, 7 Oct 2024 14:27:09 +0200 Message-ID: <20241007122709.215901-1-alexander.heinisch@siemens.com> MIME-Version: 1.0 X-Flowmailer-Platform: Siemens Feedback-ID: 519:519-1326448:519-21489:flowmailer X-Original-Sender: alexander.heinisch@siemens.com X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@siemens.com header.s=fm2 header.b=CNh0ssTx; spf=pass (google.com: domain of fm-1326448-20241007122733dd046c1202fb51ff1d-p_x6pe@rts-flowmailer.siemens.com designates 185.136.64.228 as permitted sender) smtp.mailfrom=fm-1326448-20241007122733dd046c1202fb51ff1d-p_x6Pe@rts-flowmailer.siemens.com; dmarc=pass (p=REJECT sp=REJECT dis=NONE) header.from=siemens.com X-Original-From: alexander.heinisch@siemens.com Reply-To: alexander.heinisch@siemens.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list isar-users@googlegroups.com; contact isar-users+owners@googlegroups.com List-ID: X-Spam-Checked-In-Group: isar-users@googlegroups.com X-Google-Group-Id: 914930254986 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , X-Spam-Status: No, score=-2.2 required=5.0 tests=DKIMWL_WL_MED,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,MAILING_LIST_MULTI, RCVD_IN_DNSWL_BLOCKED,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,RCVD_IN_PSBL, RCVD_IN_RP_CERTIFIED,RCVD_IN_RP_RNBL,RCVD_IN_RP_SAFE,SPF_PASS autolearn=unavailable autolearn_force=no version=3.4.2 X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on shymkent.ilbers.de X-TUID: otMvIfOg08Nd From: Alexander Heinisch Currently, it is only possible to specify a unix timestamp to resolve the snapshot version used. Since this is not very user friendly, most downstream projects put comments like `# 20240702T082400Z` next to the snapshot assignment `ISAR_APT_SNAPSHOT_TIMESTAMP = ...`. This patch makes it easier for users to specify the snapshot version in a more natural way by `ISAR_APT_SNAPSHOT_DATE = 20240702T082400Z` Signed-off-by: Alexander Heinisch --- v2: Added documentation v3: Renamed APT_SNAPSHOT_DATE to ISAR_APT_SNAPSHOT_DATE doc/user_manual.md | 3 ++- kas/opt/Kconfig | 2 +- meta-isar/conf/distro/ubuntu-common.inc | 2 +- meta/conf/distro/debian-common.conf | 2 +- meta/recipes-core/isar-bootstrap/isar-bootstrap.inc | 4 ++-- 5 files changed, 7 insertions(+), 6 deletions(-) diff --git a/doc/user_manual.md b/doc/user_manual.md index 706c74bf..cf3c3b12 100644 --- a/doc/user_manual.md +++ b/doc/user_manual.md @@ -435,7 +435,8 @@ Some other variables include: - `ISAR_USE_APT_SNAPSHOT` - Use a frozen apt snapshot instead of the live mirror. Optional. `ISAR_APT_DL_LIMIT` - Rate limit the apt fetching to n kB / s. Optional. - `DISTRO_APT_SNAPSHOT_PREMIRROR` - Similar to `DISTRO_APT_PREMIRRORS` but for a snapshot, pre-defined for supported distros. - - `ISAR_APT_SNAPSHOT_TIMESTAMP` - Timestamp of the apt snapshot. Automatically derived from `SOURCE_DATE_EPOCH` if not overwritten. + - `ISAR_APT_SNAPSHOT_TIMESTAMP` - Unix timestamp of the apt snapshot. Automatically derived from `SOURCE_DATE_EPOCH` if not overwritten. (Consider `ISAR_APT_SNAPSHOT_DATE` for a more user friendly format) + - `ISAR_APT_SNAPSHOT_DATE` - Timestamp in upstream format (e.g. `20240702T082400Z`) of the apt snapshot. Overrides `ISAR_APT_SNAPSHOT_TIMESTAMP` if set. Otherwise, will be automatically derived from `ISAR_APT_SNAPSHOT_TIMESTAMP` - `THIRD_PARTY_APT_KEYS` - List of gpg key URIs used to verify apt repos for apt installation after bootstrapping. - `FILESEXTRAPATHS` - The default directories BitBake uses when it processes recipes are initially defined by the FILESPATH variable. You can extend FILESPATH variable by using FILESEXTRAPATHS. - `FILESOVERRIDES` - A subset of OVERRIDES used by the build system for creating FILESPATH. The FILESOVERRIDES variable uses overrides to automatically extend the FILESPATH variable. diff --git a/kas/opt/Kconfig b/kas/opt/Kconfig index 65482e3a..1e56c29f 100644 --- a/kas/opt/Kconfig +++ b/kas/opt/Kconfig @@ -44,7 +44,7 @@ config USE_APT_SNAPSHOT bool "Use the distros snapshot mirror" depends on !MIRROR_DEBIAN && (DEBIAN_BUSTER || DEBIAN_BULLSEYE || DEBIAN_BOOKWORM || DEBIAN_TRIXIE || DEBIAN_SID || UBUNTU_FOCAL || UBUNTU_JAMMY) help - Use a snapshot mirror for the selected distribution. The date is defined by ISAR_APT_SNAPSHOT_TIMESTAMP. + Use a snapshot mirror for the selected distribution. The date is defined by ISAR_APT_SNAPSHOT_DATE. config KAS_INCLUDE_APT_SNAPSHOT string diff --git a/meta-isar/conf/distro/ubuntu-common.inc b/meta-isar/conf/distro/ubuntu-common.inc index 232bee35..be7fd047 100644 --- a/meta-isar/conf/distro/ubuntu-common.inc +++ b/meta-isar/conf/distro/ubuntu-common.inc @@ -37,4 +37,4 @@ SYSTEMD_BOOTLOADER_INSTALL:focal = "systemd:${DISTRO_ARCH}" SYSTEMD_BOOTLOADER_INSTALL:jammy = "systemd:${DISTRO_ARCH}" # snapshot mirror for reproducible builds -DISTRO_APT_SNAPSHOT_PREMIRROR ??= "(http|https)://archive.ubuntu.com/(.*) https://snapshot.ubuntu.com/\2/${APT_SNAPSHOT_DATE}/\n" +DISTRO_APT_SNAPSHOT_PREMIRROR ??= "(http|https)://archive.ubuntu.com/(.*) https://snapshot.ubuntu.com/\2/${ISAR_APT_SNAPSHOT_DATE}/\n" diff --git a/meta/conf/distro/debian-common.conf b/meta/conf/distro/debian-common.conf index 8c6a3f63..65b5b083 100644 --- a/meta/conf/distro/debian-common.conf +++ b/meta/conf/distro/debian-common.conf @@ -40,4 +40,4 @@ COMPAT_DISTRO_ARCH:amd64 = "i386" COMPAT_DISTRO_ARCH:arm64 = "armhf" # snapshot mirror for reproducible builds -DISTRO_APT_SNAPSHOT_PREMIRROR ??= "deb.debian.org/(.*) snapshot.debian.org/archive/\1/${APT_SNAPSHOT_DATE}/\n" +DISTRO_APT_SNAPSHOT_PREMIRROR ??= "deb.debian.org/(.*) snapshot.debian.org/archive/\1/${ISAR_APT_SNAPSHOT_DATE}/\n" diff --git a/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc b/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc index 12f32ff0..92974eb5 100644 --- a/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc +++ b/meta/recipes-core/isar-bootstrap/isar-bootstrap.inc @@ -34,7 +34,7 @@ DISTRO_VARS_PREFIX ?= "${@'HOST_' if bb.utils.to_boolean(d.getVar('BOOTSTRAP_FOR BOOTSTRAP_DISTRO = "${@d.getVar('HOST_DISTRO' if bb.utils.to_boolean(d.getVar('BOOTSTRAP_FOR_HOST')) else 'DISTRO')}" BOOTSTRAP_BASE_DISTRO = "${@d.getVar('HOST_BASE_DISTRO' if bb.utils.to_boolean(d.getVar('BOOTSTRAP_FOR_HOST')) else 'BASE_DISTRO')}" FILESEXTRAPATHS:append = ":${BBPATH}" -APT_SNAPSHOT_DATE = "${@ get_apt_snapshot_date(d)}" +ISAR_APT_SNAPSHOT_DATE ?= "${@ get_isar_apt_snapshot_date(d)}" inherit deb-dl-dir @@ -110,7 +110,7 @@ def parse_aptsources_list_line(source_list_line): return [type, options, source, suite, components] -def get_apt_snapshot_date(d): +def get_isar_apt_snapshot_date(d): import time source_date_epoch = d.getVar('ISAR_APT_SNAPSHOT_TIMESTAMP') return time.strftime('%Y%m%dT%H%M%SZ', time.gmtime(int(source_date_epoch))) -- 2.43.0 -- You received this message because you are subscribed to the Google Groups "isar-users" group. To unsubscribe from this group and stop receiving emails from it, send an email to isar-users+unsubscribe@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/isar-users/20241007122709.215901-1-alexander.heinisch%40siemens.com.