From patchwork Thu Aug 22 17:11:25 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Antonio Terceiro X-Patchwork-Id: 19425 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ve0-f200.google.com (mail-ve0-f200.google.com [209.85.128.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 37119248E6 for ; Thu, 22 Aug 2013 17:11:28 +0000 (UTC) Received: by mail-ve0-f200.google.com with SMTP id oz10sf1828853veb.3 for ; Thu, 22 Aug 2013 10:11:27 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-gm-message-state:delivered-to:mime-version:to:from:subject :message-id:date:reply-to:sender:errors-to:precedence :x-original-sender:x-original-authentication-results:mailing-list :list-id:list-post:list-help:list-archive:list-unsubscribe :content-type; bh=ZYk7vEnOxj7XEIxen8uscBY7Rjc8H2l6ZtZ2cJ2ZeT0=; b=LfGB5ONuPn5W+XQZ0qY8KjvEDLtJsc00Y/OE3D/z01M0aOOb/twgmPUDvpOpYy9Gk/ U0PVoJ25y2vQgWUp5xjy5MWm7NqJX2fP3LhUB1e2e8R2YKfqgKc1q9LGOBkGXg6mMTSf SPCsEVuq5kBWuK6MAucYPTFR+RmqLp99R9VKhWsuwiHfzh5JFZIF5ScOviHGzUmdsIor pgY3qJddqDsCGGly7eDwIY9CeO+GQZ7V26007kh/p2dKE2kSnt3U9La69zKD6PWDIFf8 f+M6FW/q8wcO37q6s4aS8w90exEK8YheBIZQ4meFXLMmkJWZGjBvN7fThXStxbBT5BXb TyTg== X-Received: by 10.236.4.69 with SMTP id 45mr4751900yhi.20.1377191487769; Thu, 22 Aug 2013 10:11:27 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.49.127.99 with SMTP id nf3ls1210991qeb.83.gmail; Thu, 22 Aug 2013 10:11:27 -0700 (PDT) X-Received: by 10.220.48.194 with SMTP id s2mr21879vcf.43.1377191487671; Thu, 22 Aug 2013 10:11:27 -0700 (PDT) Received: from mail-ve0-f173.google.com (mail-ve0-f173.google.com [209.85.128.173]) by mx.google.com with ESMTPS id xe6si4283813vdb.61.1969.12.31.16.00.00 (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Thu, 22 Aug 2013 10:11:27 -0700 (PDT) Received-SPF: neutral (google.com: 209.85.128.173 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.173; Received: by mail-ve0-f173.google.com with SMTP id cy12so1747682veb.18 for ; Thu, 22 Aug 2013 10:11:27 -0700 (PDT) X-Gm-Message-State: ALoCoQkQFBc4Py3X4XXtBxWE+lhOmQhi/FK1vBR4ublHzXCdEfW/MKQ20VBu70R0Ey1wjGixmNDD X-Received: by 10.220.182.69 with SMTP id cb5mr21011vcb.41.1377191487588; Thu, 22 Aug 2013 10:11:27 -0700 (PDT) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patches@linaro.org Received: by 10.220.174.196 with SMTP id u4csp42658vcz; Thu, 22 Aug 2013 10:11:26 -0700 (PDT) X-Received: by 10.180.205.236 with SMTP id lj12mr10711727wic.22.1377191486316; Thu, 22 Aug 2013 10:11:26 -0700 (PDT) Received: from indium.canonical.com (indium.canonical.com. [91.189.90.7]) by mx.google.com with ESMTPS id vt5si8717461wjc.113.1969.12.31.16.00.00 (version=TLSv1 cipher=RC4-SHA bits=128/128); Thu, 22 Aug 2013 10:11:26 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of bounces@canonical.com designates 91.189.90.7 as permitted sender) client-ip=91.189.90.7; Received: from ackee.canonical.com ([91.189.89.26]) by indium.canonical.com with esmtp (Exim 4.71 #1 (Debian)) id 1VCYPt-0003ar-HD for ; Thu, 22 Aug 2013 17:11:25 +0000 Received: from ackee.canonical.com (localhost [127.0.0.1]) by ackee.canonical.com (Postfix) with ESMTP id 6EAE7E0818 for ; Thu, 22 Aug 2013 17:11:25 +0000 (UTC) MIME-Version: 1.0 X-Launchpad-Project: lava-dispatcher X-Launchpad-Branch: ~linaro-validation/lava-dispatcher/trunk X-Launchpad-Message-Rationale: Subscriber X-Launchpad-Branch-Revision-Number: 656 X-Launchpad-Notification-Type: branch-revision To: Linaro Patch Tracker From: noreply@launchpad.net Subject: [Branch ~linaro-validation/lava-dispatcher/trunk] Rev 656: Requires being run as root Message-Id: <20130822171125.22718.25063.launchpad@ackee.canonical.com> Date: Thu, 22 Aug 2013 17:11:25 -0000 Reply-To: noreply@launchpad.net Sender: bounces@canonical.com Errors-To: bounces@canonical.com Precedence: list X-Generated-By: Launchpad (canonical.com); Revision="16737"; Instance="launchpad-lazr.conf" X-Launchpad-Hash: 38693cd5c54c07532cf49c539766c16f4475d4db X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: noreply@launchpad.net X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.173 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org List-ID: X-Google-Group-Id: 836684582541 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , ------------------------------------------------------------ revno: 656 fixes bug: https://launchpad.net/bugs/1070309 committer: Antonio Terceiro branch nick: requires-root timestamp: Thu 2013-08-22 13:01:35 -0300 message: Requires being run as root Save time from everyone since down the road root permissions will be needed. Just fail right away if no running as root. modified: lava/dispatcher/commands.py --- lp:lava-dispatcher https://code.launchpad.net/~linaro-validation/lava-dispatcher/trunk You are subscribed to branch lp:lava-dispatcher. To unsubscribe from this branch go to https://code.launchpad.net/~linaro-validation/lava-dispatcher/trunk/+edit-subscription === modified file 'lava/dispatcher/commands.py' --- lava/dispatcher/commands.py 2013-07-16 15:58:16 +0000 +++ lava/dispatcher/commands.py 2013-08-22 16:01:35 +0000 @@ -73,6 +73,11 @@ ) def invoke(self): + + if os.getuid() != 0: + logging.error("lava dispatch has to be run as root") + exit(1) + if self.args.oob_fd: oob_file = os.fdopen(self.args.oob_fd, 'w') else: