From owner-freebsd-cloud@freebsd.org Mon Mar 11 19:25:01 2019 Return-Path: Delivered-To: freebsd-cloud@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id 47C5E152ACDE for ; Mon, 11 Mar 2019 19:25:01 +0000 (UTC) (envelope-from raf@rafal.net) Received: from smtp-out-2.mxes.net (smtp-out-2.mxes.net [205.237.194.127]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mx1.freebsd.org (Postfix) with ESMTPS id 52631771D8 for ; Mon, 11 Mar 2019 19:25:00 +0000 (UTC) (envelope-from raf@rafal.net) Received: from Customer-MUA (mua.mxes.net [10.0.0.1]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.mxes.net (Postfix) with ESMTPSA id 754D02755D; Mon, 11 Mar 2019 15:24:56 -0400 (EDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rafal.net; s=tm; t=1552332297; bh=DE2z7uj9D5LsN7cfdlEVi6S3YuYCoP+P+mK3ZVPJn+I=; h=Subject:From:In-Reply-To:Date:Cc:References:To:From; b=qUV/kw9Te5XRqkP5dP3dhgt9hkHVwxZJMT50yi2DsK5XC2X5faiaMG7iP0BhWN8iB XcOOnj1KkJV+h2TBmsugS6oXFqBal3Uw5Gj0NE7q2pCjUTYJdGFwSNyMascOjvPlrX fawGZDwZ5Dlc2pjMN1C+O4srdKpqRR0r44i+nYJw= Content-Type: text/plain; charset=utf-8 Mime-Version: 1.0 (Mac OS X Mail 12.2 \(3445.102.3\)) Subject: Re: How to base64 encode and upload userdata for EC2 Launch Template From: Rafal Lukawiecki In-Reply-To: Date: Mon, 11 Mar 2019 19:24:54 +0000 Cc: freebsd-cloud@freebsd.org Content-Transfer-Encoding: quoted-printable Message-Id: References: <16C73F7C-3673-44CC-B59E-DA247A0C2DF7@rafal.net> To: Colin Percival X-Mailer: Apple Mail (2.3445.102.3) X-Sent-To: X-Sender: rafal.net X-Rspamd-Queue-Id: 52631771D8 X-Spamd-Bar: ------ Authentication-Results: mx1.freebsd.org; dkim=pass header.d=rafal.net header.s=tm header.b=qUV/kw9T; dmarc=pass (policy=none) header.from=rafal.net; spf=pass (mx1.freebsd.org: domain of raf@rafal.net designates 205.237.194.127 as permitted sender) smtp.mailfrom=raf@rafal.net X-Spamd-Result: default: False [-6.77 / 15.00]; ARC_NA(0.00)[]; RCVD_VIA_SMTP_AUTH(0.00)[]; R_DKIM_ALLOW(-0.20)[rafal.net:s=tm]; NEURAL_HAM_MEDIUM(-1.00)[-1.000,0]; FROM_HAS_DN(0.00)[]; TO_DN_SOME(0.00)[]; R_SPF_ALLOW(-0.20)[+ip4:205.237.194.0/25]; MV_CASE(0.50)[]; MIME_GOOD(-0.10)[text/plain]; IP_SCORE(-3.21)[ip: (-8.40), ipnet: 205.237.192.0/20(-4.20), asn: 10607(-3.36), country: US(-0.07)]; NEURAL_HAM_LONG(-1.00)[-1.000,0]; TO_MATCH_ENVRCPT_SOME(0.00)[]; MX_GOOD(-0.01)[cached: mxin.mxes.net]; DKIM_TRACE(0.00)[rafal.net:+]; RCPT_COUNT_TWO(0.00)[2]; NEURAL_HAM_SHORT(-0.95)[-0.953,0]; DMARC_POLICY_ALLOW(-0.50)[rafal.net,none]; RCVD_IN_DNSWL_LOW(-0.10)[127.194.237.205.list.dnswl.org : 127.0.5.1]; FROM_EQ_ENVFROM(0.00)[]; MIME_TRACE(0.00)[0:+]; ASN(0.00)[asn:10607, ipnet:205.237.192.0/20, country:US]; MID_RHS_MATCH_FROM(0.00)[]; RCVD_TLS_ALL(0.00)[]; RCVD_COUNT_TWO(0.00)[2] X-BeenThere: freebsd-cloud@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "FreeBSD on cloud platforms \(EC2, GCE, Azure, etc.\)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 11 Mar 2019 19:25:01 -0000 I have been using =E2=80=9Ctar cvyf fff ddd=E2=80=9D, which I think is a = compressed tarball using bzip. Should I use something else? I have also noticed odd behaviour in the Console for LCs, but different = behaviour in the Console for LCs, and yet different for CLI=E2=80=A6 Thank you, Colin. Rafal > On 11 Mar 2019, at 19:21, Colin Percival wrote: >=20 > On 3/11/19 2:42 AM, Rafal Lukawiecki wrote: >> I hope someone can explain, as I have been lost in this for over a = week. I would like to pass a small (4-5kB) tarball of files for the = built-in cloud init script of the official FreeBSD 12.0 EC2 AMI to get = untarred and processed (>, >>, or #!) upon instance launch. I have = successfully done it for over 2 years using Launch Configurations but I = cannot make it work using the new Launch Templates. >=20 > Is this a tarball, or a compressed tarball? >=20 > There's a longstanding bug (which I'm told is going to get fixed = eventually!) > in the AWS Console whereby any non-7-bit-clean user-data files get = mangled > and come out with each byte UTF-8 encoded. I was only aware of this = as an > issue with the Console but it's entirely possible that someone at = Amazon wrote > the same bug in multiple places. >=20 > --=20 > Colin Percival > Security Officer Emeritus, FreeBSD | The power to serve > Founder, Tarsnap | www.tarsnap.com | Online backups for the truly = paranoid