From nobody Wed Jun 05 09:03:07 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 4VvM1l3Zl7z5MDSn; Wed, 05 Jun 2024 09:03:07 +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 "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4VvM1l2TMPz4Nl7; Wed, 5 Jun 2024 09:03:07 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1717578187; 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=0CvP76hz2O1Yk0tUsbnosZhhHw1gG1TJUfPxiF4ya9U=; b=IQ60+ptJrFTMj5Qf2S/J3j0dq1KmImrqX1+VOEw6PUJtHBTpPHqmpVomgblgIDcsKRWFwj AYvh9wxy/tsNZOxsAP/BXMbTCq6/w7e6xeK2kjadjqJEjnYi/MYRopubkh+0gC4eAEJfxB CIIIRfj082TyoWeDJCvJuGsl2oX4vygyqAEAq7noF4fc9szcNYiHayQ8VdmYVihOgE/S3M 3UJD/3BDcTyLWylnfEbnDHN9ijbAGzM7wMxGFIgyeR23FZ5ksY55Kktym33ZR/9miUiUB0 JYIg6d0ToX99peEmJHwEj7ULV4Xu3J9JRiY61BMmgO05hnxQqwgk/pR6EtAO/g== ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1717578187; a=rsa-sha256; cv=none; b=xqWTpYft2smoewNt0gVsYXzbtES2UMlx+22zpKhQAeudmWqlU+WoqGljhxp0hXyJuzhytM 4vSr+YgG+TB5v7nUuMjTYW6j3LV8D8a9R+L1bnMmAo1YUhms66CEerHLbRA85gzohCaOej vKLsdHkzZ174UslYZkNiByizm27dvElWlNU38PqUI6UOxQDNQ/LMxLRHDRdEJVsaU7BTyb lOSdsmktVL3vIE+IZvl6DAGq59Nz6ybZUnZO8SusX61bDDktuUWCsRdtlJnFS7bYXcep7f tafR38U/8LV00zBpRBkDg/djgW7lIeNxEqZ7q+ltlRiPi7L4jSHMitNYZlr/zg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1717578187; 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=0CvP76hz2O1Yk0tUsbnosZhhHw1gG1TJUfPxiF4ya9U=; b=sgUUHghxZSpgRyJyZC79awE+wO4CysmblpfBZ9cXGJNqKddj2vk7+wWbZX6MUUEMxtIrOb YfRrzaOLrO1OYYH8CZACHo2fhDzrnjueT26PrNBbXwRNIB1D+bj0i3GCa8oMtRZ78uxowR dfKYBEHT8ywKdtJZjFYtnkUzYwQTxO4ckSRxplSuh3Kp8TCFrK1s8dNimLQQDnzDLxieNK TlFllPUYasPJ35UYt1rYUZCOmFNrHZgRl6ixCGUE3bnIyIdkTU1PgWWXk9ycSrunCzalEs aRm4Le8y8ik0aHVY/UjzZiJ/Coc79NnrWM9dExyEepKlhTXzpIXQD2PYAk+uaw== 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 4VvM1l25ckzwlR; Wed, 5 Jun 2024 09:03:07 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.17.1/8.17.1) with ESMTP id 4559377Q093404; Wed, 5 Jun 2024 09:03:07 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.17.1/8.17.1/Submit) id 455937l5093401; Wed, 5 Jun 2024 09:03:07 GMT (envelope-from git) Date: Wed, 5 Jun 2024 09:03:07 GMT Message-Id: <202406050903.455937l5093401@gitrepo.freebsd.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org From: Baptiste Daroussin Subject: git: fa07b02f6e09 - main - nuageinit: make addsshkey friendly for testsuite 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: bapt X-Git-Repository: src X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: fa07b02f6e09f776b3afe5709e8fee1764c11a2a Auto-Submitted: auto-generated The branch main has been updated by bapt: URL: https://cgit.FreeBSD.org/src/commit/?id=fa07b02f6e09f776b3afe5709e8fee1764c11a2a commit fa07b02f6e09f776b3afe5709e8fee1764c11a2a Author: Baptiste Daroussin AuthorDate: 2024-06-05 08:44:17 +0000 Commit: Baptiste Daroussin CommitDate: 2024-06-05 09:00:53 +0000 nuageinit: make addsshkey friendly for testsuite --- libexec/nuageinit/nuage.lua | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/libexec/nuageinit/nuage.lua b/libexec/nuageinit/nuage.lua index 020b54b0776c..ca70c778791b 100644 --- a/libexec/nuageinit/nuage.lua +++ b/libexec/nuageinit/nuage.lua @@ -177,6 +177,10 @@ end local function addsshkey(homedir, key) local chownak = false local chowndotssh = false + local root = os.getenv("NUAGE_FAKE_ROOTDIR") + if root then + homedir = root .. "/" .. homedir + end local ak_path = homedir .. "/.ssh/authorized_keys" local dotssh_path = homedir .. "/.ssh" local dirattrs = lfs.attributes(ak_path)