]> git.ipfire.org Git - thirdparty/mkosi.git/commitdiff
Pass WITH_NETWORK to build and finalize scripts
authorJörg Behrmann <behrmann@physik.fu-berlin.de>
Thu, 16 May 2024 12:55:58 +0000 (14:55 +0200)
committerDaan De Meyer <daan.j.demeyer@gmail.com>
Thu, 16 May 2024 13:30:27 +0000 (15:30 +0200)
mkosi/__init__.py
mkosi/resources/mkosi.md

index 945975ebb86248703db95fc036398c416a0a1a58..ce4638c27e439305868dc52769d298fbdfeeb09b 100644 (file)
@@ -718,6 +718,7 @@ def run_postinst_scripts(context: Context) -> None:
         MKOSI_UID=str(INVOKING_USER.uid),
         MKOSI_GID=str(INVOKING_USER.gid),
         MKOSI_CONFIG="/work/config.json",
+        WITH_NETWORK=one_zero(context.config.with_network),
         **GIT_ENV,
     )
 
@@ -784,6 +785,7 @@ def run_finalize_scripts(context: Context) -> None:
         MKOSI_UID=str(INVOKING_USER.uid),
         MKOSI_GID=str(INVOKING_USER.gid),
         MKOSI_CONFIG="/work/config.json",
+        WITH_NETWORK=one_zero(context.config.with_network),
         **GIT_ENV,
     )
 
index 96a082314d04280032c858c01b073253eeaeeb14..b76f8622d44cf0a13d6d7fc2cf1b374201579516 100644 (file)
@@ -2295,7 +2295,7 @@ Consult this table for which script receives which environment variables:
 | `ARTIFACTDIR`       |                   |              | x               | x             | x                | x                |               |
 | `WITH_DOCS`         |                   |              | X               | X             |                  |                  |               |
 | `WITH_TESTS`        |                   |              | X               | X             |                  |                  |               |
-| `WITH_NETWORK`      |                   |              | X               | X             |                  |                  |               |
+| `WITH_NETWORK`      |                   |              | X               | X             | x                | x                |               |
 | `SOURCE_DATE_EPOCH` |                   |              | X               | X             | X                | X                | X             |
 | `MKOSI_UID`         | X                 | X            | X               | X             | X                | X                | X             |
 | `MKOSI_GID`         | X                 | X            | X               | X             | X                | X                | X             |