From patchwork Wed Oct 16 12:10:12 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Stephen Finucane X-Patchwork-Id: 1177847 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.ozlabs.org (lists.ozlabs.org [203.11.71.2]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 46tWPH5jGrz9sP7 for ; Wed, 16 Oct 2019 23:11:47 +1100 (AEDT) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=that.guru Authentication-Results: ozlabs.org; dkim=fail reason="key not found in DNS" (0-bit key; unprotected) header.d=that.guru header.i=@that.guru header.b="agdw8HEY"; dkim-atps=neutral Received: from bilbo.ozlabs.org (lists.ozlabs.org [IPv6:2401:3900:2:1::3]) by lists.ozlabs.org (Postfix) with ESMTP id 46tWPH4kSNzDqcy for ; Wed, 16 Oct 2019 23:11:47 +1100 (AEDT) X-Original-To: patchwork@lists.ozlabs.org Delivered-To: patchwork@lists.ozlabs.org Authentication-Results: lists.ozlabs.org; spf=none (no SPF record) smtp.mailfrom=that.guru (client-ip=172.82.139.144; helo=qrelay144.mxroute.com; envelope-from=stephen@that.guru; receiver=) Authentication-Results: lists.ozlabs.org; dmarc=none (p=none dis=none) header.from=that.guru Authentication-Results: lists.ozlabs.org; dkim=fail reason="key not found in DNS" (0-bit key; unprotected) header.d=that.guru header.i=@that.guru header.b="agdw8HEY"; dkim-atps=neutral Received: from qrelay144.mxroute.com (qrelay144.mxroute.com [172.82.139.144]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by lists.ozlabs.org (Postfix) with ESMTPS id 46tWNm6S6qzDqFv for ; Wed, 16 Oct 2019 23:11:20 +1100 (AEDT) Received: from filter004.mxroute.com (unknown [116.203.155.46]) (using TLSv1.2 with cipher ADH-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by qrelay144.mxroute.com (Postfix) with ESMTPS id 1180B1209A2; Wed, 16 Oct 2019 08:11:17 -0400 (EDT) Received: from one.mxroute.com (one.mxroute.com [195.201.59.211]) by filter004.mxroute.com (Postfix) with ESMTPS id EF6423F4ED; Wed, 16 Oct 2019 12:11:14 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=that.guru; s=default; h=Content-Transfer-Encoding:MIME-Version:Message-Id:Date:Subject: Cc:To:From:Sender:Reply-To:Content-Type:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:List-Subscribe: List-Post:List-Owner:List-Archive; bh=VDqcVgPWi5rkIxNrrJH8tIYpOgI3i+dyvd/hiZ2WA8Q=; b=agdw8HEYM31BTIwLgjEXuJm9IM nwAi5yr133MwCOmgtdaDZEiWht/2D5KNjwNq0wDnTQOXQzwQfrwg29NynW2tnOEnaWTwPdwi+xVI2 Qq5QCHupkKOe8nxNxvmxzKUOxisBGQ/pUzf6OsIantiQHqp083FoFF4hmSqjGRl0oKE/F02yN6lcl tzxZqf5qUlORfRonHzjJ9EKKfq4g+XcqU0xqlCJycO25ee2WoNjBqDV1+BLhMFtvvwMhPEv1mu72R BgpQDHRGIl11GmUaKrUAl+MRGUbxGR4WF2jTEOlq6ziiJWOFrxOIzGs/Byhk76hWqDg5HnRS7uQO3 bvj7cGnw==; From: Stephen Finucane To: patchwork@lists.ozlabs.org Subject: [PATCH 1/3] docker: Rely on caching Date: Wed, 16 Oct 2019 13:10:12 +0100 Message-Id: <20191016121014.29201-1-stephen@that.guru> X-Mailer: git-send-email 2.21.0 MIME-Version: 1.0 X-AuthUser: stephen@that.guru X-BeenThere: patchwork@lists.ozlabs.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Patchwork development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: patchwork-bounces+incoming=patchwork.ozlabs.org@lists.ozlabs.org Sender: "Patchwork" It seems less likely that tox and tox-pyenv will change than our requirements. Split up the 'RUN' steps so we don't have to reinstall the former every time the latter change. Signed-off-by: Stephen Finucane --- tools/docker/Dockerfile | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git tools/docker/Dockerfile tools/docker/Dockerfile index 35324b13..a8e85ef0 100644 --- tools/docker/Dockerfile +++ tools/docker/Dockerfile @@ -47,15 +47,12 @@ RUN pyenv latest install 2.7 && \ pyenv latest install 3.5 && \ pyenv latest install 3.6 && \ pyenv latest install 3.7 - RUN pyenv global $(pyenv versions --bare | tac) -COPY requirements-*.txt /tmp/ -RUN pip install tox tox-pyenv && \ - pip install -r /tmp/requirements-dev.txt +RUN pip install tox tox-pyenv -# we deliberately leave the requirements files in tmp so we can -# ping the user in entrypoint.sh if the change them! +COPY requirements-dev.txt requirements-test.txt /opt/ +RUN pip install -r /opt/requirements-dev.txt COPY tools/docker/entrypoint.sh /usr/local/bin/entrypoint.sh ENTRYPOINT ["/usr/local/bin/entrypoint.sh"]