nodejs reactive layer
Adam Stokes
adam.stokes at canonical.com
Mon Oct 19 15:08:55 UTC 2015
Additionally I was hoping I could just layer my application on top of the
nodejs layer and have my node version available to the application layer so
it would look like:
- base layer
- node layer
- application api layer
The application api layer would then have access to node/npm during charm
deployment and be able to react to node's layer state. However, in testing
this out it doesn't look like my application layer ever gets executed once
the node layer has finished.
My thinking was that in order to test multiple node versions for my
application all I would need to do is deploy the charm with the node layers
default version configuration. To give you a better idea this is my api
service layer for an application I have:
https://github.com/wffm/juju-layer-wffmapi
That layer inherits from my node layer which inherits the base layer. I was
hoping to keep each layer's responsibility to just one thing, ie node layer
only installs node.js and exposes its installed state.
On Mon, Oct 19, 2015 at 9:23 AM, Adam Stokes <adam.stokes at canonical.com>
wrote:
> I'm looking to get my nodejs layer[1] included at
> http://interfaces.juju.solutions and wanted to make sure that this charm
> can be properly tested. I noticed that a Makefile is generated during
> `charm-compose` and was curious how I can utilize that with amulet or
> whatever the preferred way to test charms is. The amulet documentation
> doesn't really go into how to actually run the tests locally so I can
> easily verify my charm. Is there a how-to on the preferred (blessed) way of
> testing charms locally?
>
> For the curious my charm layer simply installs Node.js based on whatever
> version you set in the config (0.10, 0.12, 4.x) and will be used when
> deploying whatever node app you require.
>
> Oh one other thing, I didn't see how to pass config options in amulet's
> deploy so that I can test my different default versions from the config.
>
> 1: https://github.com/battlemidget/juju-layer-node
>
> Thanks!
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.ubuntu.com/archives/juju/attachments/20151019/463f1ff1/attachment.html>
More information about the Juju
mailing list