RE: Validate csar file in Aria-0.1.1

2018-02-28 Thread D Jayachandran
Hi Sudhakar,

Thanks for raising this issue. Do you mean we are not extracting the CSAR as 
such ?

Regards,
DJ
From: Sudhakar Reddy [mailto:sudhakar.re...@amdocs.com]
Sent: Wednesday, February 28, 2018 5:34 PM
To: dev@ariatosca.incubator.apache.org
Subject: Validate csar file in Aria-0.1.1

Hi,

I'm trying to validate & store the service-template which is a csar extension 
file.

The actual service template is available under Definitions folder and is not 
present on the root folder. Even the Metadata present in 
TOSCA.meta:Entry-Definitions defines the path of the service-template to be 
inside Definitions folder.

But when I checked the aria code, we are taking the service template file name 
and checking on the root directory where the csar extracted. Why don't we 
consider the template  which is under Definitions/ ??

[X][cid:image002.png@01D3B0BA.619D22D0]

Thanks & Regards
Sudhakar Reddy
Contact No:8758383421

This message and the information contained herein is proprietary and 
confidential and subject to the Amdocs policy statement,
you may review at https://www.amdocs.com/about/email-disclaimer


Aria support for TOSCA-simple-1.1

2018-02-28 Thread Sudhakar Reddy
Hi,

I want to know whether we are in the process of giving the support for TOSCA 
definition: simple_yaml_1_1?

As currently ONAP uses 1.1 version yaml to create the service model, the same 
won't be validated by aria. Let me know your inputs on this.

Thanks & Regards
Sudhakar Reddy
Contact No:8758383421

This message and the information contained herein is proprietary and 
confidential and subject to the Amdocs policy statement,

you may review at https://www.amdocs.com/about/email-disclaimer 



Re: Issue in the execution context when using Openstack plugin

2018-02-28 Thread DeWayne Filppi
So in other words, the Openstack plugin is irrelevant. What you are saying
is that somehow the dependency itself causes ssh to be used in a
SoftwareComponent type.  If you run a blueprint just with the "prep" node,
it works fine as expected?

DeWayne

On Wed, Feb 28, 2018 at 9:09 AM, Pedro Henrique Gomes <
pedrohenriquego...@gmail.com> wrote:

> Hi Thomas, thank you for your reply.
>
> The point is that the node that complains about not having the ssh
> credentials, has a HOST that should be running locally, not thru ssh.
>
> The output error that I get is below:
>
> 13:57:32 | E |
> aria.orchestrator.execution_plugin.operations.run_script_with_ssh |
> {u'process': {}, u'script_path': u'scripts/prep.sh', u'use_sudo': False,
> u'fabric_env': {'password': '', 'key_filename': None, 'user': '', 'key':
> None}, u'hide_output': []} | prep_software Standard.create failed
> |Traceback (most recent call last):
> |  File
> "/tmp/pip-build-7lUI8E/apache-ariatosca/aria/orchestrator/
> workflows/executor/process.py",
> line 342, in _main
> |  File
> "/home/pedro/aria/env/local/lib/python2.7/site-packages/
> adapters/context_adapter.py",
> line 436, in wrapper
> |function(ctx=ctx, **operation_inputs)
> |  File
> "/home/pedro/aria/env/local/lib/python2.7/site-packages/
> aria/orchestrator/decorators.py",
> line 78, in _wrapper
> |return func(**func_kwargs)
> |  File
> "/home/pedro/aria/env/local/lib/python2.7/site-packages/
> aria/orchestrator/execution_plugin/operations.py",
> line 51, in run_script_with_ssh
> |**kwargs)
> |  File
> "/home/pedro/aria/env/local/lib/python2.7/site-packages/
> aria/orchestrator/execution_plugin/ssh/operations.py",
> line 67, in run_script
> |**_fabric_env(ctx, fabric_env, warn_only=False)):
> |  File
> "/home/pedro/aria/env/local/lib/python2.7/site-packages/
> aria/orchestrator/execution_plugin/ssh/operations.py",
> line 157, in _fabric_env
> |'Access credentials not supplied '
> |  File
> "/home/pedro/aria/env/local/lib/python2.7/site-packages/
> aria/modeling/orchestration.py",
> line 446, in abort
> |raise TaskAbortException(message)
> |TaskAbortException: Access credentials not supplied (you must supply
> at least one of `key_filename`, `key` or `password`)
>
> 13:57:33 | I | install | {} | 'install' workflow execution failed
>
> I can try to provide to you a minimum viable template to execute and get
> the same error.
> But if you have any idea from this log, please let me know, any tip is
> useful.
>
> Regards
>
> On Tue, Feb 27, 2018 at 4:35 PM Thomas Nadeau 
> wrote:
>
> > It looks like you answered your own question. When you require SSH by
> > calling "execute_with_ssh" but do not have it configured, its not going
> to
> > work right? *)
> >
> > In any event, can you provide more diagnostic info so that we can see
> > better where things are failing. I am actually starting to work on
> > improving the return error/warning codes now, so its timely.
> >
> > --Tom
> >
> >
> > On Tue, Feb 27, 2018 at 2:08 PM, Pedro Henrique Gomes <
> > pedrohenriquego...@gmail.com> wrote:
> >
> > > Hello everyone,
> > >
> > > I am having a problem with a template that uses Cloudify Openstack
> > plugin.
> > > Wanted to check out if someone has any clue, because it seems to be a
> > bug.
> > > I can open a ticket if necessary.
> > >
> > > I have a template that creates a Openstack deployment with a VM.
> > >
> > > --- In scenario 1) there is a node (call N1) in the template of type
> > > tosca.nodes.SoftwareComponent that executes some scripts in the VM
> (using
> > > ssh). This node has as requirement host the later VM.
> > > This scenario works fine
> > >
> > > -- In scenario 2) there is a node (call N2) in the template also of
> type
> > > tosca.nodes.SoftwareComponent, but this other node run locally, not in
> > the
> > > VM.
> > > If both nodes exist they work fine but I dont have control over which
> one
> > > runs first
> > >
> > > -- In scenario 3) we add a requirement dependency to N1 pointing to
> N2. I
> > > want to make sure the scripts in N2 run before the scripts in N1.
> > > But in this case both nodes (N1 and N2) are executed with
> > > execute_with_ssh() which makes the orchestration break, because N2 does
> > not
> > > have a sh key, etc.
> > >
> > > The snippet from the template is below
> > >
> > > prep_server:
> > >   type: ServerType
> > >
> > > prep_software:
> > >   type: tosca.nodes.SoftwareComponent
> > >   requirements:
> > > - host: prep_server
> > > - dependency: vm_1
> > >  interfaces:
> > > Standard:
> > >   create: scripts/prep.sh
> > >
> > > configure_software:
> > >   type: tosca.nodes.SoftwareComponent
> > > requirements:
> > >   - host: vm_1
> > > #- dependency: prep_software
> > > interfaces:
> > >   Standard:
> > > configure:
> > >   implementation:
> > > primary: scripts/configure.sh
> > >  

Re: Issue in the execution context when using Openstack plugin

2018-02-28 Thread Pedro Henrique Gomes
Hi Thomas, thank you for your reply.

The point is that the node that complains about not having the ssh
credentials, has a HOST that should be running locally, not thru ssh.

The output error that I get is below:

13:57:32 | E |
aria.orchestrator.execution_plugin.operations.run_script_with_ssh |
{u'process': {}, u'script_path': u'scripts/prep.sh', u'use_sudo': False,
u'fabric_env': {'password': '', 'key_filename': None, 'user': '', 'key':
None}, u'hide_output': []} | prep_software Standard.create failed
|Traceback (most recent call last):
|  File
"/tmp/pip-build-7lUI8E/apache-ariatosca/aria/orchestrator/workflows/executor/process.py",
line 342, in _main
|  File
"/home/pedro/aria/env/local/lib/python2.7/site-packages/adapters/context_adapter.py",
line 436, in wrapper
|function(ctx=ctx, **operation_inputs)
|  File
"/home/pedro/aria/env/local/lib/python2.7/site-packages/aria/orchestrator/decorators.py",
line 78, in _wrapper
|return func(**func_kwargs)
|  File
"/home/pedro/aria/env/local/lib/python2.7/site-packages/aria/orchestrator/execution_plugin/operations.py",
line 51, in run_script_with_ssh
|**kwargs)
|  File
"/home/pedro/aria/env/local/lib/python2.7/site-packages/aria/orchestrator/execution_plugin/ssh/operations.py",
line 67, in run_script
|**_fabric_env(ctx, fabric_env, warn_only=False)):
|  File
"/home/pedro/aria/env/local/lib/python2.7/site-packages/aria/orchestrator/execution_plugin/ssh/operations.py",
line 157, in _fabric_env
|'Access credentials not supplied '
|  File
"/home/pedro/aria/env/local/lib/python2.7/site-packages/aria/modeling/orchestration.py",
line 446, in abort
|raise TaskAbortException(message)
|TaskAbortException: Access credentials not supplied (you must supply
at least one of `key_filename`, `key` or `password`)

13:57:33 | I | install | {} | 'install' workflow execution failed

I can try to provide to you a minimum viable template to execute and get
the same error.
But if you have any idea from this log, please let me know, any tip is
useful.

Regards

On Tue, Feb 27, 2018 at 4:35 PM Thomas Nadeau  wrote:

> It looks like you answered your own question. When you require SSH by
> calling "execute_with_ssh" but do not have it configured, its not going to
> work right? *)
>
> In any event, can you provide more diagnostic info so that we can see
> better where things are failing. I am actually starting to work on
> improving the return error/warning codes now, so its timely.
>
> --Tom
>
>
> On Tue, Feb 27, 2018 at 2:08 PM, Pedro Henrique Gomes <
> pedrohenriquego...@gmail.com> wrote:
>
> > Hello everyone,
> >
> > I am having a problem with a template that uses Cloudify Openstack
> plugin.
> > Wanted to check out if someone has any clue, because it seems to be a
> bug.
> > I can open a ticket if necessary.
> >
> > I have a template that creates a Openstack deployment with a VM.
> >
> > --- In scenario 1) there is a node (call N1) in the template of type
> > tosca.nodes.SoftwareComponent that executes some scripts in the VM (using
> > ssh). This node has as requirement host the later VM.
> > This scenario works fine
> >
> > -- In scenario 2) there is a node (call N2) in the template also of type
> > tosca.nodes.SoftwareComponent, but this other node run locally, not in
> the
> > VM.
> > If both nodes exist they work fine but I dont have control over which one
> > runs first
> >
> > -- In scenario 3) we add a requirement dependency to N1 pointing to N2. I
> > want to make sure the scripts in N2 run before the scripts in N1.
> > But in this case both nodes (N1 and N2) are executed with
> > execute_with_ssh() which makes the orchestration break, because N2 does
> not
> > have a sh key, etc.
> >
> > The snippet from the template is below
> >
> > prep_server:
> >   type: ServerType
> >
> > prep_software:
> >   type: tosca.nodes.SoftwareComponent
> >   requirements:
> > - host: prep_server
> > - dependency: vm_1
> >  interfaces:
> > Standard:
> >   create: scripts/prep.sh
> >
> > configure_software:
> >   type: tosca.nodes.SoftwareComponent
> > requirements:
> >   - host: vm_1
> > #- dependency: prep_software
> > interfaces:
> >   Standard:
> > configure:
> >   implementation:
> > primary: scripts/configure.sh
> >   dependencies:
> > - "ssh.user > ubuntu"
> > - "ssh.key_filename > ./key.pem"
> > - "ssh.address > { get_attribute: [ virtual_ip,
> > floating_ip_address ] }"
> >
> > If I have the template above nodes prep_software and configure_software
> > execute correctly in the desired machine. If the comment above is
> removed,
> > both nodes are executed with execute_with_ssh()
> >
> >
> > Hoe someone can help me or provide any direction for this problem
> >
> > Thanks
> >
> >
> > --
> > Pedro Henrique Gomes
> > www.pedrohenriquegomes.com.br
> > +1-310-3101429 

Validate csar file in Aria-0.1.1

2018-02-28 Thread Sudhakar Reddy
Hi,

I'm trying to validate & store the service-template which is a csar extension 
file.

The actual service template is available under Definitions folder and is not 
present on the root folder. Even the Metadata present in 
TOSCA.meta:Entry-Definitions defines the path of the service-template to be 
inside Definitions folder.

But when I checked the aria code, we are taking the service template file name 
and checking on the root directory where the csar extracted. Why don't we 
consider the template  which is under Definitions/ ??

[cid:image001.png@01D3B0BA.619D22D0][cid:image002.png@01D3B0BA.619D22D0]

Thanks & Regards
Sudhakar Reddy
Contact No:8758383421

This message and the information contained herein is proprietary and 
confidential and subject to the Amdocs policy statement,

you may review at https://www.amdocs.com/about/email-disclaimer