News for hackers. Stuff that matters.
Re:Microsoft and Docker team up to make packaging cloud-nati... by gabrtv on Tuesday December 04, 2018 @12:10PM (#18601318)
Gabe from Microsoft here. Happy to answer any questions. A few links to help you explore the spec and tooling:

- https://cnab.io

- https://duffle.sh/

- https://open.microsoft.com/2018/12/04/announcing-cnab-cloud-...

Re:Microsoft and Docker team up to make packaging cloud-nati... by mcny on Tuesday December 04, 2018 @02:09PM (#18602665)
Thank you for being here and answering questions. Is there any way you can (internally) push to remove roadblocks for the insanity of Windows Home vs Pro for Docker/Hyper-V? I know this isn't possible in the short run but I think it prevents a lot of children from getting started with Docker.

Based on what Scott Guttrie's team has been able to accomplish, I am cautiously optimistic that this is possible if there is enough push for it from within Microsoft. Thank you once again for your support!

Re:Microsoft and Docker team up to make packaging cloud-nati... by beavis2 on Tuesday December 04, 2018 @05:20PM (#18604110)
If you want to play the "think of the children" card, then let's start by discouraging development on Windows.
Re:Microsoft and Docker team up to make packaging cloud-nati... by scarface74 on Tuesday December 04, 2018 @07:20PM (#18604740)
I would discourage development for Windows but not necessarily on Windows. I develop on Windows and deploy to Linux all of the time. I also have started using the Linux subsystem for Windows.

I’ve been developing for and on Windows for over 20 years. The “Windows Tax” didn’t become a concern of mine until I started using cloud providers. The cost of Microsoft’s licenses was someone else’s problem.

But, when every resource you use is tagged and it’s very clear how much you’re spending on an implementation, the double hit of Windows becomes real. First you pay more for Windows VMs than the same size Linux VMs and then you need more resources.

I can do a lot with a 256Mb-512Mb RAM Linux VM. I at least need 4GB of RAM for Windows and that’s stretching it.

On the other hand, I still love .Net Core but it’s not getting the uptake that Node is or even Java - yes that makes me sad.

Re:Microsoft and Docker team up to make packaging cloud-nati... by nikanj on Tuesday December 04, 2018 @11:50PM (#18605771)
Why do you need 8x more memory for Windows? The NT kernel isn’t 8x worse than Linux, not even close.
Re:Microsoft and Docker team up to make packaging cloud-nati... by tialaramex on Wednesday December 05, 2018 @04:28AM (#18606828)
It's a philosophical difference. NT doesn't do overcommit. In theory overcommit is dangerous (and if you decide that matters you can tell Linux not to do it) but in practice it's usually a huge RAM saving.

If your apparent virtual size is 2.6GB but there's actually only 240MB of resident memory, Linux will run on 256MB of RAM. NT requires enough RAM for the entire 2.6GB plus overheads.

This is especially frustrating if you have orchestration services that would have recovered from the unlikely event of OOM since avoiding OOM is literally the only reason for NT's choice.

Re:Microsoft and Docker team up to make packaging cloud-nati... by ahje on Wednesday December 05, 2018 @02:19AM (#18606291)
Personally, I've run small LAMP stacks on VPS's with 256 MB RAM and without major issues. Running a web server on a Windows VPS usually requires more than that (albeit not 8 time as much.
Re:Microsoft and Docker team up to make packaging cloud-nati... by ecnahc515 on Tuesday December 04, 2018 @07:37PM (#18604821)
A lot of families already have a Windows computer and not everyone can afford a spare computer to run Linux on, and some people's PCs can't run a full Linux in a VM either.

Windows has a lot of ways to develop for Linux/Unix now. It sure isn't FOSS, but let's not discourage a promising way to get more people into software, even if it's on Windows.

Re:Microsoft and Docker team up to make packaging cloud-nati... by geggam on Tuesday December 04, 2018 @10:02PM (#18605386)
Installing Linux over Windows is still free.
Re:Microsoft and Docker team up to make packaging cloud-nati... by KAKAN on Wednesday December 05, 2018 @02:22AM (#18606303)
The "installing" part is the problem here. I installed Manjaro XFCE in my parents' old PCs, and they're now enjoying it. They never did it because they didn't know how to and didn't want to destroy their already working, but slow PC. Teach that, and I'm pretty sure everyone would love the customizability that the world of Linux provides.
Re:Microsoft and Docker team up to make packaging cloud-nati... by geggam on Wednesday December 05, 2018 @05:23AM (#18607062)
I would think any developer should be able to install ubuntu these days.
Re:Microsoft and Docker team up to make packaging cloud-nati... by vtesucks on Tuesday December 04, 2018 @10:22PM (#18605459)
Do you have any specific points or you're just trying to be edgy?

Hint- no circular arguments allowed. For example- UNIX line endings are '\n' so they are better so look UNIX is better. I mention this because I've heard this from my friends none of whom have ever programmed a raw terminal.

Re:Microsoft and Docker team up to make packaging cloud-nati... by arduinomancer on Tuesday December 04, 2018 @08:39PM (#18605107)
^^^ This is actually a real barrier believe it or not.

We actually chose not to use Docker for a group project in undergrad because some group members didn't have Windows Pro.

Re:Microsoft and Docker team up to make packaging cloud-nati... by donmcronald on Tuesday December 04, 2018 @12:40PM (#18601648)
I wonder if I'm misunderstanding. Why would I want install, uninstall, etc. type actions running in a Docker container? Isn't that going to encourage people to spin up production environments that aren't reproducible?

I'm not very familiar with Ansible, etc., so maybe tools like that have strategies for building deterministic environments, but I can see a lot of people putting `apt-get` or `yum` commands in an install script.

Re:Microsoft and Docker team up to make packaging cloud-nati... by gabrtv on Tuesday December 04, 2018 @01:22PM (#18602120)
CNAB makes reproducibility possible by providing unified lifecycle management, packaging, and distribution. Of course if bundle authors don't take care to work around problems with imperative logic, that's a risk. In practice, we see declarative models for building bundles offer more reproducibility.

For example, see how you can build a CNAB using a Terraform base image: https://github.com/deislabs/bundles/tree/master/terraform

Re:Microsoft and Docker team up to make packaging cloud-nati... by donmcronald on Tuesday December 04, 2018 @01:48PM (#18602404)
Yeah. I read through some of those existing configs and I see how it works now. My first instinct when I see `cnab/app/run install` is to think it's for installing the app, but now I see it's for provisioning / deploying to the environment. As soon as I think of install, uninstall as deploy, undeploy then it clicks for me.
Re:Microsoft and Docker team up to make packaging cloud-nati... by bacongobbler on Tuesday December 04, 2018 @02:46PM (#18602996)
We may want to discuss changing the keywords from install/uninstall to be deploy/uninstall if that helps signal to the user the intent behind those actions. That's great feedback, thank you!
Re:Microsoft and Docker team up to make packaging cloud-nati... by mnoorali on Tuesday December 04, 2018 @01:18PM (#18602077)
The goal with CNAB is to be able to version your application with all of its components and then ship that as one logical unit making it reproducible. The package format is flexible enough to let you use the tooling that you're already using.
Re:Microsoft and Docker team up to make packaging cloud-nati... by politician on Tuesday December 04, 2018 @12:44PM (#18601692)
Do CNAB bundles support the ability to specify where parameter and credential details might be fetched from?

Currently, we provide developers with lab environments that wire together a small subset of containers under Docker compose for local development because running the full system is impractical. However, most of our lab environments may have important external dependencies (i.e. Slack, SMTP gateways, etc) that require configuration and often secrets.

One challenge of maintaining these lab environments is keeping these external configuration details up to date, so it would be helpful if the CNAB spec allowed configuration of this sort to be provided by an external provider similar to how Docker images themselves are expected to be provided by a container registry.

Have you anticipated this use case? If so, does CNAB have this type of support?

Re:Microsoft and Docker team up to make packaging cloud-nati... by gabrtv on Tuesday December 04, 2018 @01:09PM (#18601969)
Yes. See credential sets in the specification.

https://github.com/deislabs/cnab-spec/blob/master/802-creden...

Re:Microsoft and Docker team up to make packaging cloud-nati... by politician on Tuesday December 04, 2018 @01:24PM (#18602138)
Thanks Gabe, this looks promising.
Re:Microsoft and Docker team up to make packaging cloud-nati... by politician on Tuesday December 04, 2018 @12:19PM (#18601416)
Are there plans to work with CNCF on this spec to gain a broader consensus?

EDIT: As a cloud systems architect, I view participation in CNCF as a positive signal.

Re:Microsoft and Docker team up to make packaging cloud-nati... by gabrtv on Tuesday December 04, 2018 @12:24PM (#18601477)
Yes. The intention has always been to put CNAB and related tooling into a foundation that offers vendor-neutral IP ownership. That could be CNCF, OCI, or something else.
Re:Microsoft and Docker team up to make packaging cloud-nati... by sytse on Tuesday December 04, 2018 @02:32PM (#18602884)
The announcement talks about "reliably provision application resources in different environments". Does that mean multiple clouds?

I'm asking because in the Ansible example in https://github.com/deislabs/bundles/blob/master/ansiblebase/... I see AZURE_TENANT AZURE_CLIENT_ID AZURE_SECRET AZURE_SUBSCRIPTION_ID but nothing for other clouds.

Would you have to add configuration for every cloud you have to support?

Re:Microsoft and Docker team up to make packaging cloud-nati... by mnoorali on Tuesday December 04, 2018 @02:37PM (#18602914)
The format is cloud agnostic. Here is an example of a bundle that Bitnami built that provisions wordpress and Amazon RDS https://github.com/bitnami/cnab-bundles/tree/master/wordpres...
Re:Microsoft and Docker team up to make packaging cloud-nati... by sytse on Tuesday December 04, 2018 @02:57PM (#18603082)
Thanks! In https://github.com/bitnami/cnab-bundles/blob/master/wordpres... I see AWS but not Azure.

It seems that in this context cloud agnostic means any cloud can be supported.

I'm interested in application portability [0]. To do this with CNAB you need to add every cloud to the bundle. This is contrast to something like Crossplane [1] that intents to support multi-cloud with a single specification.

0. https://medium.com/gitlab-magazine/multi-cloud-maturity-mode...

1. https://news.ycombinator.com/item?id=18600603#18601961

Re:Microsoft and Docker team up to make packaging cloud-nati... by bdburns on Tuesday December 04, 2018 @03:08PM (#18603182)
You can build a kubernetes based bundle that is cloud agnostic.
Re:Microsoft and Docker team up to make packaging cloud-nati... by amouat on Wednesday December 05, 2018 @07:52AM (#18607755)
I'm a little confused by this.

I get the specification is cloud agnostic. But it looks like the developer needs to write the underlying code to provision and maintain the application on the various clouds. It feels like a too thin abstraction. And it seems pretty leaky currently; the examples all have hard and specific requirements e.g. Azure, k8s etc.

What am I missing? Is the idea that we will create tooling to automatically create the provisioning and maintenance code?

Re:Microsoft and Docker team up to make packaging cloud-nati... by ilaksh on Tuesday December 04, 2018 @02:44PM (#18602974)
How is this not just an alternative to normal Docker tools?

Does it run on Linux?

Re:Microsoft and Docker team up to make packaging cloud-nati... by bGl2YW5j on Tuesday December 04, 2018 @06:39PM (#18604522)
> How is this not just an alternative to normal Docker tools?

From my understanding, you've got Docker for defining your app's services, you've got Kubernetes for orchestrating them, you've got Terraform et al. for defining/configuring your infrastructure, and now you've got CNAB/Duffle to bring all these tools and configs together under one umbrella.

> Does it run on Linux?

From the article[1] posted above:

> By design, it is cloud agnostic. It works with everything from Azure to on-prem OpenStack, from Kubernetes to Swarm, and from Ansible to Terraform. It can execute on a workstation, a public cloud, an air-gapped network, or a constrained IoT environment.

[1] https://open.microsoft.com/2018/12/04/announcing-cnab-cloud-...

Re:Microsoft and Docker team up to make packaging cloud-nati... by ravedave5 on Tuesday December 04, 2018 @12:50PM (#18601763)
I am one of those people who learn through examples. Do you have an example of using duffle for defining some sort of application? I work with this stuff and the websites are so abstract as to what it does and the spec is so low level...
Re:Microsoft and Docker team up to make packaging cloud-nati... by mnoorali on Tuesday December 04, 2018 @12:53PM (#18601794)
Absolutely! You can find some example bundles here: https://aka.ms/example-bundles
Re:Microsoft and Docker team up to make packaging cloud-nati... by mnoorali on Tuesday December 04, 2018 @12:59PM (#18601862)
Here is also a video of us running through some examples to give you a high level walkthrough of CNAB https://www.youtube.com/watch?v=26e5-UK4YRA
Re:Microsoft and Docker team up to make packaging cloud-nati... by chanezon on Wednesday December 05, 2018 @12:47PM (#18610569)
You can find some preview binaries of docker-app with CNAB support as well as a few simple examples at https://github.com/docker/app#cnab-support-preview
Re:Microsoft and Docker team up to make packaging cloud-nati... by outside1234 on Tuesday December 04, 2018 @02:22PM (#18602809)
I'm even more confused after watching this video. Is the right way to think about this that it is a common specification that enables helm and compose to interoperate?
Re:Microsoft and Docker team up to make packaging cloud-nati... by polskibus on Tuesday December 04, 2018 @02:09PM (#18602659)
Does it work with Windows Server and Windows 10 the same way that docker does? Can it be utilized without docker?
Re:Microsoft and Docker team up to make packaging cloud-nati... by patrickaljord on Tuesday December 04, 2018 @02:47PM (#18603003)
Is it possible to run duffle bundles on my kubernetes cluster right now? Couldn't find any docs. Thanks!
Re:Microsoft and Docker team up to make packaging cloud-nati... by mnoorali on Tuesday December 04, 2018 @03:00PM (#18603109)
Yea absolutely. Check out the hellohelm bundle for a simple example: https://github.com/deislabs/bundles/tree/master/hellohelm and the Bitnami Wordpress + Amazon RDS bundle for one with multiple components: https://github.com/bitnami/cnab-bundles/tree/master/wordpres...
Re:Microsoft and Docker team up to make packaging cloud-nati... by patrickaljord on Tuesday December 04, 2018 @03:32PM (#18603339)
What would be the advantage over just using helm directly? (not a criticism, I'm not a big helm user for now, just kubectl but would like to know the difference for future project). Do you plan to integrate CNAB into kubernetes directly so we can bypass helm in the future?
Re:Microsoft and Docker team up to make packaging cloud-nati... by gabrtv on Tuesday December 04, 2018 @05:02PM (#18603988)
If you're only using Kubernetes, straight Helm might be a better fit.

But imagine you need to run your Helm chart on Kubernetes environment that doesn't have access to your container images. You could build a thick bundle from your Helm chart, put it on USB stick, sneaker-net it over to a disconnected Kubernetes cluster, hydrate a container registry and run the Helm chart with full fidelity in the new environment.

This is just one thing CNAB enables..