nearform / nscale

Deployment just got easy
http://nscale.nearform.com/
Artistic License 2.0
325 stars 23 forks source link

Standardise Container / Container Def fields #67

Open mcdonnelldean opened 9 years ago

mcdonnelldean commented 9 years ago

Looking over the various analyzers I note that the fields required in the container / container def objects vary from project to project and even type to type. If this was standardised it would make regression easier to manage and improve readability in my opinion.

Having looked over them all I think this is a good proposal for standard:

{
  "name": "nsd-test",
  "namespace": "nsd",
  "id": "4624e815-f814-4802-89b4-e33340a6af46",
  "containerDefinitions": [
    {
      "id": "id",
      "nativeId": "nativeId",
      "name": "name",
      "type": "type",
      "specific": {}
    }
  ],
  "topology": {
    "containers": {
      "id": {
        "id": "id",
        "nativeId": "nativeId",
        "name": "name",
        "containedBy": null,
        "containerDefinitionId": "definitionId",
        "contains": [
        "containerId"
        ],
        "type": "",
        "tags": {
          "tag": "value"
        },
        "specific": {
          "key": "value"
        }
      }
    }
  }
}
mcollina commented 9 years ago

I agree.

Here is the problem: all clouds/systems etc have different ways for doing the same thing. Contrary to AWS, in docker tags do not have values.

Before standardizing anything, I think we should collect this scattered information somewhere, document it, and cover some other clouds, like Google's and DigitalOcean. Once we figure out how nscale can work everywhere, we can standardize knowing we do not leave a cloud out.

mcdonnelldean commented 9 years ago

@mcollina sounds good, I've started to put a sample output in the test/data folder of each project. Once these are all done we would be in a better position to discuss this. I have Azure and AWS done. I'll look into the rest also!