From nobody Mon Oct 21 10:00:16 2024 X-Original-To: dev-commits-src-all@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4XX9m05339z5Yn8j; Mon, 21 Oct 2024 10:00:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R11" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4XX9m04JL5z4vTx; Mon, 21 Oct 2024 10:00:16 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729504816; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tgP6lxZgo6fKf6SNvD6OWsVicrWvmfBBKbLOmAwrNhM=; b=Lr39fxOcLeTiIuJ6FJ4JgfL9obfs4mmzSL6zVVBjdu0F/t6INE4CksDoUfAU5WFJRR/fWO 98wGemYLkm/vVpR14p6mNoVkYTAg6jDPIPWRmcd4u0swRmnSoky0H5Hq8ZZYybyH3rAlhq e8rlqq1DcIMFrELe/pbbXN3qVk6x7RXn0SdBsBULoh/5iH+CA2eLXh5NjCW1LR85TCmRTv wd8TrdEj10EOWhBhUgjGmw5NIHMgcE3jjwVFyiza/IH17LZmw2IhRpdQ/AUNORLuX8FmJH 7iZJat5SrztLPIceMKozDySOMvY+LdbTgfs9JOW0z6y6pXD8Yspbjubg43foTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1729504816; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=tgP6lxZgo6fKf6SNvD6OWsVicrWvmfBBKbLOmAwrNhM=; b=ye8QRT21W9hsLPOre+lPQpyK6GzdkLP6FQB/EnI9gpTCrEx1Sg9PMFvQb07bjhvjyl3SKA yA+mEMNf2fURE1kd6zkKhrGwMEpgx19Xz9n3YIvJBRdZAYL2odncVFYh+xiYcWuJBkjnVz oUTqmIQaiKR7N+2sKVi2rkRl1A8QP2ondzH5bhuUx2gKHq1Voqz4ursBqoNFaSIInipxyU UsyagIAIisPqA3jBdDvQsgG7STMlB3dgdybGVjnxVNyGyrB9oG8E5FFX/48zkKWM5HG/sz oPYFbIykXREaz/u2LfFEsyyCfQHC6xNlYo4bmOd5hRLpsnfErfu8/IINz334uQ== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1729504816; a=rsa-sha256; cv=none; b=ZHgFExKy6gIlq/Q/ZSgWbNELXynNURFeBCSrY8R8rq1JCQlAYFw0uwgQdZCYD8G8UivfeY s15i2HH90Qomay1G6klOYoIM9eP98wnd9fhWtZpXiTVRE6/uKeOwpAOJwuv0G2Bur6X1xc ks92LeKW4cjSzpSn9P99SQAmork9r3abznL3/w6lLIp/HA53SvJRDwJ6mfwC5o3n9DEgJZ phTT5F8BCKiz8oc9ucyhV47vbMClyajQCHGoyvRVPjq4D2gvQID3pToPByipL+FlUNUyNz +jIzkSeUofg7pmTN+YUuGQt+F01SLDRdTKqLlGC2aUXZ3QRzhpskrAtWyFZFPA== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4XX9m03w2JzPcr; Mon, 21 Oct 2024 10:00:16 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.18.1/8.18.1) with ESMTP id 49LA0G5T080067; Mon, 21 Oct 2024 10:00:16 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.18.1/8.18.1/Submit) id 49LA0GBd080058; Mon, 21 Oct 2024 10:00:16 GMT (envelope-from git) Date: Mon, 21 Oct 2024 10:00:16 GMT Message-Id: <202410211000.49LA0GBd080058@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-branches@FreeBSD.org From: Mateusz Piotrowski <0mp@FreeBSD.org> Subject: git: 025535f94525 - stable/14 - rc/tests: Skip oomprotect tests in a jail List-Id: Commit messages for all branches of the src repository List-Archive: https://lists.freebsd.org/archives/dev-commits-src-all List-Help: List-Post: List-Subscribe: List-Unsubscribe: X-BeenThere: dev-commits-src-all@freebsd.org Sender: owner-dev-commits-src-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: 0mp X-Git-Repository: src X-Git-Refname: refs/heads/stable/14 X-Git-Reftype: branch X-Git-Commit: 025535f94525c78202d829eb45d8f1ba7253ba46 Auto-Submitted: auto-generated The branch stable/14 has been updated by 0mp: URL: https://cgit.FreeBSD.org/src/commit/?id=025535f94525c78202d829eb45d8f1ba7253ba46 commit 025535f94525c78202d829eb45d8f1ba7253ba46 Author: Mateusz Piotrowski <0mp@FreeBSD.org> AuthorDate: 2024-10-14 10:28:47 +0000 Commit: Mateusz Piotrowski <0mp@FreeBSD.org> CommitDate: 2024-10-21 09:59:16 +0000 rc/tests: Skip oomprotect tests in a jail oomprotect cannot be used in a jail. Reviewed by: bnovkov, christos, markj Approved by: bnovkov (mentor), christos (mentor), markj (mentor) MFC after: 1 week (cherry picked from commit 6fa42b91ca3f481912af98c4d49c44507eb1b8e1) --- libexec/rc/tests/rc_subr_test.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/libexec/rc/tests/rc_subr_test.sh b/libexec/rc/tests/rc_subr_test.sh index 90306de9a8a7..f004354fe52e 100644 --- a/libexec/rc/tests/rc_subr_test.sh +++ b/libexec/rc/tests/rc_subr_test.sh @@ -35,6 +35,10 @@ oomprotect_all_head() oomprotect_all_body() { + if [ "$(sysctl -n security.jail.jailed)" != 0 ]; then + atf_skip "protect(1) cannot be used in a jail" + fi + __name="$(atf_get ident)" __pidfile="$(mktemp -t "${__name}.pid")" __childpidfile="$(mktemp -t "${__name}.childpid")" @@ -72,6 +76,10 @@ oomprotect_yes_head() oomprotect_yes_body() { + if [ "$(sysctl -n security.jail.jailed)" != 0 ]; then + atf_skip "protect(1) cannot be used in a jail" + fi + __name="$(atf_get ident)" __pidfile="$(mktemp -t "${__name}.pid")" __script=$(mktemp -t "${__name}.script")