From owner-svn-src-all@freebsd.org Sun May 17 23:48:53 2020 Return-Path: Delivered-To: svn-src-all@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id AAFA02F93A4; Sun, 17 May 2020 23:48:53 +0000 (UTC) (envelope-from oliver.pntr@gmail.com) Received: from mail-yb1-xb33.google.com (mail-yb1-xb33.google.com [IPv6:2607:f8b0:4864:20::b33]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "smtp.gmail.com", Issuer "GTS CA 1O1" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 49QJkr5Ppyz3cw9; Sun, 17 May 2020 23:48:52 +0000 (UTC) (envelope-from oliver.pntr@gmail.com) Received: by mail-yb1-xb33.google.com with SMTP id g79so739348ybf.0; Sun, 17 May 2020 16:48:52 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc; bh=lmwHmp4A8ZA/WR7e3VkwCHvsJk3lf3dh3G57oD/mRf8=; b=lPQpIlb85LLEQxOw8nxPrPdIWufFDQ+JIwjQdAso8/KdJdK7MdqCWXqrlZ090ucHs6 jziJW/K8yCUYLikQjD2mr7s44IxLa7Kh4s7gxjzL+EzJSmXNmb2OyAPTzBZeQopGAxrA N8wNxT8QRfoNQ5Bci7mNS5alSL7mAqcuNw273B9O80keJ0Oq5KxF0oo4tQbKzxiI2s6i 0kbld172RDcvvaQxWAJdlPmNiMVazXP9o8C/Ow1Xg/fbYXomcBNE32RK9dtZ+oR6cNjD ShDys3CZ+22RaiVcBtE+vElPVH/JUGLEHysIxwluL9/s0WYBdJn4wQtJZT0S2IssX0D2 uUnw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:in-reply-to:references:from:date :message-id:subject:to:cc; bh=lmwHmp4A8ZA/WR7e3VkwCHvsJk3lf3dh3G57oD/mRf8=; b=HHEARf21CYGWjLuDX+vY1BL3L4BmrX9+UiE1kMU7zJ9nt04wFrHqFZ2E9wUAfPcBz8 B+TowAVQJlB9Vt5uEtq5ojDJHI9KMJ/TFJTaZJljmw5w6nBc5BYNo7QHqn1bUjT8Yzm7 nUy53ohzYofW5x2eF/qNkdtooNTWvAVk8xNYJxN+nR+RYb7ibDV1FuLEoQLNV/cCpsPl 9U3dTy+6gdnDUNSzTciI49/iRGzyU237L1EsDzfQhOQ32CKQxboUyDKisNuBuSGN0+8i +g6vSQ6kbtoMJHgP6y/tZC6uWpp+gITSXbi1hEro9TtzlKX7m417zdpGnVh0wtkDjjYK sl5A== X-Gm-Message-State: AOAM532Y5NlXSocp4EIJ2FR57BCDDYuk9QpFNej8+Z4ZWgoH5NVnRwPK tieM0Ogp0lZC9s9HPp9upAYtE2T8PM1Oq0O7qMF2nw== X-Google-Smtp-Source: ABdhPJwkh3kGaglGyXwt6DHJMDGFvrh+KGaHhZrO/w1NSjNmv0KU+eiBb/ranJNSFA84n8z1t2cGXYgIatGCeNtTstc= X-Received: by 2002:a5b:c41:: with SMTP id d1mr3489569ybr.67.1589759331112; Sun, 17 May 2020 16:48:51 -0700 (PDT) MIME-Version: 1.0 Received: by 2002:a25:2bc5:0:0:0:0:0 with HTTP; Sun, 17 May 2020 16:48:50 -0700 (PDT) In-Reply-To: <202005172155.04HLt07J036230@repo.freebsd.org> References: <202005172155.04HLt07J036230@repo.freebsd.org> From: Oliver Pinter Date: Mon, 18 May 2020 01:48:50 +0200 Message-ID: Subject: Re: svn commit: r361143 - head/release/tools To: Colin Percival Cc: "src-committers@freebsd.org" , "svn-src-all@freebsd.org" , "svn-src-head@freebsd.org" X-Rspamd-Queue-Id: 49QJkr5Ppyz3cw9 X-Spamd-Bar: ---- Authentication-Results: mx1.freebsd.org; none X-Spamd-Result: default: False [-4.00 / 15.00]; REPLY(-4.00)[]; ASN(0.00)[asn:15169, ipnet:2607:f8b0::/32, country:US]; TAGGED_FROM(0.00)[] Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.33 X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 17 May 2020 23:48:53 -0000 On Sunday, May 17, 2020, Colin Percival wrote: > Author: cperciva > Date: Sun May 17 21:54:59 2020 > New Revision: 361143 > URL: https://svnweb.freebsd.org/changeset/base/361143 > > Log: > Add /etc/autofs/special_efs to EC2 AMIs > > Since Amazon Elastic File System is only available within AWS, it seems > more appropriate to have this added only in EC2 AMIs rather than > "polluting" non-EC2 images with it. > > Reviewed by: gjb > MFC after: 7 days > Relnotes: Amazon EFS filesystems can be automounted by enabling > autofs > and placing "/efs -efs" into /etc/auto_master. > Sponsored by: https://www.patreon.com/cperciva > Differential Revision: https://reviews.freebsd.org/D24791 > > Modified: > head/release/tools/ec2.conf > > Modified: head/release/tools/ec2.conf > ============================================================ > ================== > --- head/release/tools/ec2.conf Sun May 17 21:29:45 2020 (r361142) > +++ head/release/tools/ec2.conf Sun May 17 21:54:59 2020 (r361143) > @@ -113,6 +113,23 @@ vm_extra_pre_umount() { > -e '1,/^#server/s/^#server.*/server 169.254.169.123 > iburst/' \ > ${DESTDIR}/etc/ntp.conf > > + # Provide a map for accessing Elastic File System mounts > + cat > ${DESTDIR}/etc/autofs/special_efs <<'EOF' > +#!/bin/sh > + > +if [ $# -eq 0 ]; then > + # No way to know which EFS filesystems exist and are > + # accessible to this EC2 instance. > + exit 0 > +fi > + > +# Provide instructions on how to mount the requested filesystem. > +FS=$1 > +REGION=`fetch -qo- http://169.254.169.254/latest/meta-data/placement/ > availability-zone | sed -e 's/[a-z]$//'` What will be this hard-coded ip address without any verification or at least https? > +echo "-nfsv4,minorversion=1,oneopenown ${FS}.efs.${REGION}.amazonaws. > com:/" > +EOF > + chmod 755 ${DESTDIR}/etc/autofs/special_efs > + > # The first time the AMI boots, the installed "first boot" scripts > # should be allowed to run: > # * ec2_configinit (download and process EC2 user-data) > _______________________________________________ > svn-src-head@freebsd.org mailing list > https://lists.freebsd.org/mailman/listinfo/svn-src-head > To unsubscribe, send any mail to "svn-src-head-unsubscribe@freebsd.org" >