From dev-return-1616-apmail-openwhisk-dev-archive=openwhisk.apache.org@openwhisk.apache.org Sun Mar 4 11:54:01 2018 Return-Path: X-Original-To: apmail-openwhisk-dev-archive@minotaur.apache.org Delivered-To: apmail-openwhisk-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E1FAA10736 for ; Sun, 4 Mar 2018 11:54:01 +0000 (UTC) Received: (qmail 68044 invoked by uid 500); 4 Mar 2018 11:54:01 -0000 Delivered-To: apmail-openwhisk-dev-archive@openwhisk.apache.org Received: (qmail 67975 invoked by uid 500); 4 Mar 2018 11:54:01 -0000 Mailing-List: contact dev-help@openwhisk.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@openwhisk.apache.org Delivered-To: mailing list dev@openwhisk.apache.org Received: (qmail 67957 invoked by uid 99); 4 Mar 2018 11:54:01 -0000 Received: from pnap-us-west-generic-nat.apache.org (HELO spamd4-us-west.apache.org) (209.188.14.142) by apache.org (qpsmtpd/0.29) with ESMTP; Sun, 04 Mar 2018 11:54:01 +0000 Received: from localhost (localhost [127.0.0.1]) by spamd4-us-west.apache.org (ASF Mail Server at spamd4-us-west.apache.org) with ESMTP id 99C61C0040 for ; Sun, 4 Mar 2018 11:54:00 +0000 (UTC) X-Virus-Scanned: Debian amavisd-new at spamd4-us-west.apache.org X-Spam-Flag: NO X-Spam-Score: 2.148 X-Spam-Level: ** X-Spam-Status: No, score=2.148 tagged_above=-999 required=6.31 tests=[DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, FREEMAIL_ENVFROM_END_DIGIT=0.25, HTML_MESSAGE=2, RCVD_IN_DNSWL_NONE=-0.0001, RCVD_IN_MSPIKE_H2=-0.001, SPF_PASS=-0.001] autolearn=disabled Authentication-Results: spamd4-us-west.apache.org (amavisd-new); dkim=pass (2048-bit key) header.d=gmail.com Received: from mx1-lw-eu.apache.org ([10.40.0.8]) by localhost (spamd4-us-west.apache.org [10.40.0.11]) (amavisd-new, port 10024) with ESMTP id mSKiV_JcsWDv for ; Sun, 4 Mar 2018 11:53:58 +0000 (UTC) Received: from mail-ua0-f176.google.com (mail-ua0-f176.google.com [209.85.217.176]) by mx1-lw-eu.apache.org (ASF Mail Server at mx1-lw-eu.apache.org) with ESMTPS id 953BA5F485 for ; Sun, 4 Mar 2018 11:53:57 +0000 (UTC) Received: by mail-ua0-f176.google.com with SMTP id k7so1237525uaa.3 for ; Sun, 04 Mar 2018 03:53:57 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=jBp+y51Pfuv1GZo0+uOHVoKsbJUqmHR4+UqpsXkNCgM=; b=m8RkzxdNA8dbwlbd/x/IQrEEQo467EJT5x7tMZ9DNdezY1bdZXmiDHsTKb9/y2jqHF eo0icrTgMW2XNECDaC8xNJuTaBXMqnX58GZ4iLOqEYeoJTsO/gmzG0kdALwiqCB7FX47 UxpY+Asb41XVKq0xyXq9gcEgWC5CvZhGvBRdRBKcZ0+axYvT0lBpIQJsYcbY6erT6uws MFQqVAjQ7B0Lml3UagocXpop+oJngYq5Xp6WS0NjNmrbiw3O61YYYL7VbXYR43HCMIPe /SNzWWWPVz3ukX31vsybEYuJsNlIbi/if0tVH9g1uPcymei40iFA7GxF871waWdNf3bF 667w== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=jBp+y51Pfuv1GZo0+uOHVoKsbJUqmHR4+UqpsXkNCgM=; b=JqZ9HAZihp7AZsXg2jhT5PgU+w7uRxs6uxXG9eAD9mzBFxPDK6M+d5PrOO2N6mr7e9 Y3z2T63H9zxn5eHPL0IYdxvEsEih507NEL3sEWgs84ns3HZIBDCSJbLO59myrvW9rLUb p98DYBb4zp2I6hwdFElCywtd9fxVvxyusPoznkrm/JFJWM2dphunrF4tRDCJFcix+62/ /k2Me6tXC9f+cjKEIY3Wd1kN0XQv5qM9wu5n5YH6eU/7Ajyq55rCiOuO6pUN8wlZGLzT UrHzJkCRWf+n4HGRnrexI4cJf0JENXSnfJbECo//3tobzP63BW6mA9sCR/eeTtwtHQfw j8Hw== X-Gm-Message-State: APf1xPCg0dQ5LRTUYABK6c4QpeXgkXfEfdrI7ePuIWzQkqzjq2N8zoHH ZM35PYv+kaCxIKVCqCkuaNE2GHwP8QvD/N5DR9E= X-Google-Smtp-Source: AG47ELvO2YQOTpukXRGGPK26QZYJbYEohjo4Y0mN3LUvilT3cgR7qaQlm8fjEvbVx4B2xmc/sTlNi5iz/7AA0nIaWpo= X-Received: by 10.176.83.151 with SMTP id k23mr7896037uaa.167.1520164429848; Sun, 04 Mar 2018 03:53:49 -0800 (PST) MIME-Version: 1.0 References: In-Reply-To: From: Carlos Santana Date: Sun, 04 Mar 2018 11:53:39 +0000 Message-ID: Subject: Re: Using bash-based actions To: dev@openwhisk.apache.org Content-Type: multipart/alternative; boundary="f403045dccf6d76558056694dcb1" --f403045dccf6d76558056694dcb1 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Herez Perl and Bash Actions are supported is just that we need to improve the documentation to make it more explicit I=E2=80=99m working on improving doc= ker Actions documentation this week :-) Try this: wsk action update fooBash foo.sh =E2=80=94native Or wsk action update fooPerl foo.pl =E2=80=94native It can be any script file the action will chmod +x and then executed. For the second question I don=E2=80=99t know what you mean for logs. Any text to stdout and stderr before the last line with the json string result are capture in te logs in the activation record Fell free to open an issue with more info on how to reproduce your problem. =E2=80=94 Carlos PS: my employer is also IBM. :-) On Sun, Mar 4, 2018 at 5:56 AM Erez Hadad wrote: > Hi folks, > > I'm working with technical people from different organizations outside my > employer (IBM), and we're testing OpenWhisk as a mechanism for integratin= g > our different tools and services into a single heterogeneous event-driven > programming model. > On the face of it, OW seems like a great fit. > However, when it comes down to implementation, we often hit a case where > the easiest way to delegate action execution to a custom tool is by > writing a simple bash script. This is where things get complicated. > To the best of my understanding (please correct me otherwise), there is n= o > first-class support for bash runtime in OW. > So, it's down to creating either a "native" action using a zip, or a > custom docker action. Both options are quite more cumbersome than using > native runtimes. > > So this is my first question - would it make sense to have a native bash > runtime in OW? especially given that some of the function that OW > seemingly provides is glue-code between existing tools and services (wher= e > bash also shines). > > As a second issue, we explored the native action. It seems that output is > not captured in the action logs when including ssh calls that invoke bash > > My second question - does anyone have a different experience with this > that they can share? (maybe this problem is not related to OW?) > > Regards, > -- Erez Hadad > > Erez Hadad, PhD > Cloud System Technologies > IBM Research - Haifa > email: erezh@il.ibm.com > phone: +972-4-829-6509 > > > > --f403045dccf6d76558056694dcb1--