Browse code

freshen template syntax

Ben Parees authored on 2015/04/30 06:25:50
Showing 16 changed files
1 1
deleted file mode 100644
... ...
@@ -1,114 +0,0 @@
1
-{
2
-  "apiVersion": "v1beta1",
3
-  "kind": "Template",
4
-  "metadata": {
5
-    "annotations": {
6
-      "description": "This template creates a basic MongoDB database service",
7
-      "tags": "database,mongodb",
8
-      "iconClass" : "icon-mongodb"
9
-    },
10
-    "name": "mongodb"
11
-  },
12
-  "parameters": [
13
-    {
14
-      "description": "database username",
15
-      "from": "user[A-Z0-9]{3}",
16
-      "generate": "expression",
17
-      "name": "MONGODB_USER"
18
-    },
19
-    {
20
-      "description": "database password",
21
-      "from": "[a-zA-Z0-9]{8}",
22
-      "generate": "expression",
23
-      "name": "MONGODB_PASSWORD"
24
-    },
25
-    {
26
-      "description": "database name",
27
-      "name": "MONGODB_DATABASE",
28
-      "value": "sampledb"
29
-    }
30
-  ],
31
-  "labels": {
32
-    "template": "mongodb-template"
33
-  },
34
-  "items": [
35
-    {
36
-      "apiVersion": "v1beta1",
37
-      "containerPort": 27017,
38
-      "id": "mongodb",
39
-      "kind": "Service",
40
-      "port": 27017,
41
-      "selector": {
42
-        "name": "mongodb"
43
-      }
44
-    },
45
-    {
46
-      "apiVersion": "v1beta1",
47
-      "kind": "DeploymentConfig",
48
-      "metadata": {
49
-        "name": "mongodb"
50
-      },
51
-      "template": {
52
-        "controllerTemplate": {
53
-          "podTemplate": {
54
-            "desiredState": {
55
-              "manifest": {
56
-                "containers": [
57
-                  {
58
-                    "env": [
59
-                      {
60
-                        "name": "MONGODB_USER",
61
-                        "value": "${MONGODB_USER}"
62
-                      },
63
-                      {
64
-                        "name": "MONGODB_PASSWORD",
65
-                        "value": "${MONGODB_PASSWORD}"
66
-                      },
67
-                      {
68
-                        "name": "MONGODB_DATABASE",
69
-                        "value": "${MONGODB_DATABASE}"
70
-                      }
71
-                    ],
72
-                    "image": "mongodb",
73
-                    "name": "mongodb",
74
-                    "ports": [
75
-                      {
76
-                        "containerPort": 27017
77
-                      }
78
-                    ]
79
-                  }
80
-                ],
81
-                "version": "v1beta1"
82
-              }
83
-            },
84
-            "labels": {
85
-              "name": "mongodb"
86
-            }
87
-          },
88
-          "replicaSelector": {
89
-            "name": "mongodb"
90
-          },
91
-          "replicas": 1
92
-        },
93
-        "strategy": {
94
-          "type": "Recreate"
95
-        }
96
-      },
97
-      "triggers": [
98
-        {
99
-          "imageChangeParams": {
100
-            "automatic": true,
101
-            "containerNames": [
102
-              "mongodb"
103
-            ],
104
-            "from": {
105
-              "name": "mongodb-24-centos7"
106
-            },
107
-            "tag": "latest"
108
-          },
109
-          "type": "ImageChange"
110
-        }
111
-      ]
112
-    }
113
-  ]
114
-}
115 1
deleted file mode 100644
... ...
@@ -1,114 +0,0 @@
1
-{
2
-  "apiVersion": "v1beta1",
3
-  "kind": "Template",
4
-  "metadata": {
5
-    "annotations": {
6
-      "description": "This template creates a basic MongoDB database service",
7
-      "tags": "database,mongodb",
8
-      "iconClass" : "icon-mongodb"
9
-    },
10
-    "name": "mongodb"
11
-  },
12
-  "parameters": [
13
-    {
14
-      "description": "database username",
15
-      "from": "user[A-Z0-9]{3}",
16
-      "generate": "expression",
17
-      "name": "MONGODB_USER"
18
-    },
19
-    {
20
-      "description": "database password",
21
-      "from": "[a-zA-Z0-9]{8}",
22
-      "generate": "expression",
23
-      "name": "MONGODB_PASSWORD"
24
-    },
25
-    {
26
-      "description": "database name",
27
-      "name": "MONGODB_DATABASE",
28
-      "value": "sampledb"
29
-    }
30
-  ],
31
-  "labels": {
32
-    "template": "mongodb-template"
33
-  },
34
-  "items": [
35
-    {
36
-      "apiVersion": "v1beta1",
37
-      "containerPort": 27017,
38
-      "id": "mongodb",
39
-      "kind": "Service",
40
-      "port": 27017,
41
-      "selector": {
42
-        "name": "mongodb"
43
-      }
44
-    },
45
-    {
46
-      "apiVersion": "v1beta1",
47
-      "kind": "DeploymentConfig",
48
-      "metadata": {
49
-        "name": "mongodb"
50
-      },
51
-      "template": {
52
-        "controllerTemplate": {
53
-          "podTemplate": {
54
-            "desiredState": {
55
-              "manifest": {
56
-                "containers": [
57
-                  {
58
-                    "env": [
59
-                      {
60
-                        "name": "MONGODB_USER",
61
-                        "value": "${MONGODB_USER}"
62
-                      },
63
-                      {
64
-                        "name": "MONGODB_PASSWORD",
65
-                        "value": "${MONGODB_PASSWORD}"
66
-                      },
67
-                      {
68
-                        "name": "MONGODB_DATABASE",
69
-                        "value": "${MONGODB_DATABASE}"
70
-                      }
71
-                    ],
72
-                    "image": "mongodb",
73
-                    "name": "mongodb",
74
-                    "ports": [
75
-                      {
76
-                        "containerPort": 27017
77
-                      }
78
-                    ]
79
-                  }
80
-                ],
81
-                "version": "v1beta1"
82
-              }
83
-            },
84
-            "labels": {
85
-              "name": "mongodb"
86
-            }
87
-          },
88
-          "replicaSelector": {
89
-            "name": "mongodb"
90
-          },
91
-          "replicas": 1
92
-        },
93
-        "strategy": {
94
-          "type": "Recreate"
95
-        }
96
-      },
97
-      "triggers": [
98
-        {
99
-          "imageChangeParams": {
100
-            "automatic": true,
101
-            "containerNames": [
102
-              "mongodb"
103
-            ],
104
-            "from": {
105
-              "name": "mongodb-24-rhel7"
106
-            },
107
-            "tag": "latest"
108
-          },
109
-          "type": "ImageChange"
110
-        }
111
-      ]
112
-    }
113
-  ]
114
-}
115 1
new file mode 100644
... ...
@@ -0,0 +1,127 @@
0
+{
1
+  "apiVersion": "v1beta1",
2
+  "kind": "Template",
3
+  "metadata": {
4
+    "annotations": {
5
+      "description": "This template creates a basic MongoDB database service",
6
+      "tags": "database,mongodb",
7
+      "iconClass" : "icon-mongodb"
8
+    },
9
+    "name": "mongodb"
10
+  },
11
+  "parameters": [
12
+    {
13
+      "description": "database username",
14
+      "from": "user[A-Z0-9]{3}",
15
+      "generate": "expression",
16
+      "name": "MONGODB_USER"
17
+    },
18
+    {
19
+      "description": "database password",
20
+      "from": "[a-zA-Z0-9]{8}",
21
+      "generate": "expression",
22
+      "name": "MONGODB_PASSWORD"
23
+    },
24
+    {
25
+      "description": "database name",
26
+      "name": "MONGODB_DATABASE",
27
+      "value": "sampledb"
28
+    }
29
+  ],
30
+  "labels": {
31
+    "template": "mongodb-template"
32
+  },
33
+  "items": [
34
+    {
35
+      "apiVersion": "v1beta3",
36
+      "kind": "Service",
37
+      "metadata": {
38
+        "name": "mongodb"
39
+      },
40
+      "spec": {
41
+        "ports": [
42
+          {
43
+            "name": "mongo",
44
+            "port": 27017,
45
+            "protocol": "TCP",
46
+            "targetPort": 27017
47
+          }
48
+        ],
49
+        "selector": {
50
+          "name": "mongodb"
51
+        }
52
+      }
53
+    },
54
+    {
55
+      "apiVersion": "v1beta1",
56
+      "kind": "DeploymentConfig",
57
+      "metadata": {
58
+        "name": "mongodb"
59
+      },
60
+      "template": {
61
+        "controllerTemplate": {
62
+          "podTemplate": {
63
+            "desiredState": {
64
+              "manifest": {
65
+                "containers": [
66
+                  {
67
+                    "env": [
68
+                      {
69
+                        "name": "MONGODB_USER",
70
+                        "value": "${MONGODB_USER}"
71
+                      },
72
+                      {
73
+                        "name": "MONGODB_PASSWORD",
74
+                        "value": "${MONGODB_PASSWORD}"
75
+                      },
76
+                      {
77
+                        "name": "MONGODB_DATABASE",
78
+                        "value": "${MONGODB_DATABASE}"
79
+                      }
80
+                    ],
81
+                    "image": "mongodb",
82
+                    "name": "mongodb",
83
+                    "ports": [
84
+                      {
85
+                        "containerPort": 27017
86
+                      }
87
+                    ]
88
+                  }
89
+                ],
90
+                "version": "v1beta1"
91
+              }
92
+            },
93
+            "labels": {
94
+              "name": "mongodb"
95
+            }
96
+          },
97
+          "replicaSelector": {
98
+            "name": "mongodb"
99
+          },
100
+          "replicas": 1
101
+        },
102
+        "strategy": {
103
+          "type": "Recreate"
104
+        }
105
+      },
106
+      "triggers": [
107
+        {
108
+          "imageChangeParams": {
109
+            "automatic": true,
110
+            "containerNames": [
111
+              "mongodb"
112
+            ],
113
+            "from": {
114
+              "name": "mongodb"
115
+            },
116
+            "tag": "latest"
117
+          },
118
+          "type": "ImageChange"
119
+        },
120
+        {
121
+          "type": "ConfigChange"
122
+        }
123
+      ]
124
+    }
125
+  ]
126
+}
0 127
deleted file mode 100644
... ...
@@ -1,114 +0,0 @@
1
-{
2
-  "apiVersion": "v1beta1",
3
-  "kind": "Template",
4
-  "metadata": {
5
-    "annotations": {
6
-      "description": "This template creates a basic MySQL database service",
7
-      "tags": "database,mysql",
8
-      "iconClass" : "icon-mysql-database"
9
-    },
10
-    "name": "mysql"
11
-  },
12
-  "parameters": [
13
-    {
14
-      "description": "database username",
15
-      "from": "user[A-Z0-9]{3}",
16
-      "generate": "expression",
17
-      "name": "MYSQL_USER"
18
-    },
19
-    {
20
-      "description": "database password",
21
-      "from": "[a-zA-Z0-9]{8}",
22
-      "generate": "expression",
23
-      "name": "MYSQL_PASSWORD"
24
-    },
25
-    {
26
-      "description": "database name",
27
-      "name": "MYSQL_DATABASE",
28
-      "value": "sampledb"
29
-    }
30
-  ],
31
-  "labels": {
32
-    "template": "mysql-template"
33
-  },
34
-  "items": [
35
-    {
36
-      "apiVersion": "v1beta1",
37
-      "containerPort": 3306,
38
-      "id": "mysql",
39
-      "kind": "Service",
40
-      "port": 3306,
41
-      "selector": {
42
-        "name": "mysql"
43
-      }
44
-    },
45
-    {
46
-      "apiVersion": "v1beta1",
47
-      "kind": "DeploymentConfig",
48
-      "metadata": {
49
-        "name": "mysql"
50
-      },
51
-      "template": {
52
-        "controllerTemplate": {
53
-          "podTemplate": {
54
-            "desiredState": {
55
-              "manifest": {
56
-                "containers": [
57
-                  {
58
-                    "env": [
59
-                      {
60
-                        "name": "MYSQL_USER",
61
-                        "value": "${MYSQL_USER}"
62
-                      },
63
-                      {
64
-                        "name": "MYSQL_PASSWORD",
65
-                        "value": "${MYSQL_PASSWORD}"
66
-                      },
67
-                      {
68
-                        "name": "MYSQL_DATABASE",
69
-                        "value": "${MYSQL_DATABASE}"
70
-                      }
71
-                    ],
72
-                    "image": "mysql",
73
-                    "name": "mysql",
74
-                    "ports": [
75
-                      {
76
-                        "containerPort": 3306
77
-                      }
78
-                    ]
79
-                  }
80
-                ],
81
-                "version": "v1beta1"
82
-              }
83
-            },
84
-            "labels": {
85
-              "name": "mysql"
86
-            }
87
-          },
88
-          "replicaSelector": {
89
-            "name": "mysql"
90
-          },
91
-          "replicas": 1
92
-        },
93
-        "strategy": {
94
-          "type": "Recreate"
95
-        }
96
-      },
97
-      "triggers": [
98
-        {
99
-          "imageChangeParams": {
100
-            "automatic": true,
101
-            "containerNames": [
102
-              "mysql"
103
-            ],
104
-            "from": {
105
-              "name": "mysql-55-centos7"
106
-            },
107
-            "tag": "latest"
108
-          },
109
-          "type": "ImageChange"
110
-        }
111
-      ]
112
-    }
113
-  ]
114
-}
115 1
deleted file mode 100644
... ...
@@ -1,114 +0,0 @@
1
-{
2
-  "apiVersion": "v1beta1",
3
-  "kind": "Template",
4
-  "metadata": {
5
-    "annotations": {
6
-      "description": "This template creates a basic MySQL database service",
7
-      "tags": "database,mysql",
8
-      "iconClass" : "icon-mysql-database"
9
-    },
10
-    "name": "mysql"
11
-  },
12
-  "parameters": [
13
-    {
14
-      "description": "database username",
15
-      "from": "user[A-Z0-9]{3}",
16
-      "generate": "expression",
17
-      "name": "MYSQL_USER"
18
-    },
19
-    {
20
-      "description": "database password",
21
-      "from": "[a-zA-Z0-9]{8}",
22
-      "generate": "expression",
23
-      "name": "MYSQL_PASSWORD"
24
-    },
25
-    {
26
-      "description": "database name",
27
-      "name": "MYSQL_DATABASE",
28
-      "value": "sampledb"
29
-    }
30
-  ],
31
-  "labels": {
32
-    "template": "mysql-template"
33
-  },
34
-  "items": [
35
-    {
36
-      "apiVersion": "v1beta1",
37
-      "containerPort": 3306,
38
-      "id": "mysql",
39
-      "kind": "Service",
40
-      "port": 3306,
41
-      "selector": {
42
-        "name": "mysql"
43
-      }
44
-    },
45
-    {
46
-      "apiVersion": "v1beta1",
47
-      "kind": "DeploymentConfig",
48
-      "metadata": {
49
-        "name": "mysql"
50
-      },
51
-      "template": {
52
-        "controllerTemplate": {
53
-          "podTemplate": {
54
-            "desiredState": {
55
-              "manifest": {
56
-                "containers": [
57
-                  {
58
-                    "env": [
59
-                      {
60
-                        "name": "MYSQL_USER",
61
-                        "value": "${MYSQL_USER}"
62
-                      },
63
-                      {
64
-                        "name": "MYSQL_PASSWORD",
65
-                        "value": "${MYSQL_PASSWORD}"
66
-                      },
67
-                      {
68
-                        "name": "MYSQL_DATABASE",
69
-                        "value": "${MYSQL_DATABASE}"
70
-                      }
71
-                    ],
72
-                    "image": "mysql",
73
-                    "name": "mysql",
74
-                    "ports": [
75
-                      {
76
-                        "containerPort": 3306
77
-                      }
78
-                    ]
79
-                  }
80
-                ],
81
-                "version": "v1beta1"
82
-              }
83
-            },
84
-            "labels": {
85
-              "name": "mysql"
86
-            }
87
-          },
88
-          "replicaSelector": {
89
-            "name": "mysql"
90
-          },
91
-          "replicas": 1
92
-        },
93
-        "strategy": {
94
-          "type": "Recreate"
95
-        }
96
-      },
97
-      "triggers": [
98
-        {
99
-          "imageChangeParams": {
100
-            "automatic": true,
101
-            "containerNames": [
102
-              "mysql"
103
-            ],
104
-            "from": {
105
-              "name": "mysql-55-rhel7"
106
-            },
107
-            "tag": "latest"
108
-          },
109
-          "type": "ImageChange"
110
-        }
111
-      ]
112
-    }
113
-  ]
114
-}
115 1
new file mode 100644
... ...
@@ -0,0 +1,127 @@
0
+{
1
+  "apiVersion": "v1beta1",
2
+  "kind": "Template",
3
+  "metadata": {
4
+    "annotations": {
5
+      "description": "This template creates a basic MySQL database service",
6
+      "tags": "database,mysql",
7
+      "iconClass" : "icon-mysql-database"
8
+    },
9
+    "name": "mysql"
10
+  },
11
+  "parameters": [
12
+    {
13
+      "description": "database username",
14
+      "from": "user[A-Z0-9]{3}",
15
+      "generate": "expression",
16
+      "name": "MYSQL_USER"
17
+    },
18
+    {
19
+      "description": "database password",
20
+      "from": "[a-zA-Z0-9]{8}",
21
+      "generate": "expression",
22
+      "name": "MYSQL_PASSWORD"
23
+    },
24
+    {
25
+      "description": "database name",
26
+      "name": "MYSQL_DATABASE",
27
+      "value": "sampledb"
28
+    }
29
+  ],
30
+  "labels": {
31
+    "template": "mysql-template"
32
+  },
33
+  "items": [
34
+    {
35
+      "apiVersion": "v1beta3",
36
+      "kind": "Service",
37
+      "metadata": {
38
+        "name": "mysql"
39
+      },
40
+      "spec": {
41
+        "ports": [
42
+          {
43
+            "name": "mysql",
44
+            "port": 3306,
45
+            "protocol": "TCP",
46
+            "targetPort": 3306
47
+          }
48
+        ],
49
+        "selector": {
50
+          "name": "mysql"
51
+        }
52
+      }
53
+    },
54
+    {
55
+      "apiVersion": "v1beta1",
56
+      "kind": "DeploymentConfig",
57
+      "metadata": {
58
+        "name": "mysql"
59
+      },
60
+      "template": {
61
+        "controllerTemplate": {
62
+          "podTemplate": {
63
+            "desiredState": {
64
+              "manifest": {
65
+                "containers": [
66
+                  {
67
+                    "env": [
68
+                      {
69
+                        "name": "MYSQL_USER",
70
+                        "value": "${MYSQL_USER}"
71
+                      },
72
+                      {
73
+                        "name": "MYSQL_PASSWORD",
74
+                        "value": "${MYSQL_PASSWORD}"
75
+                      },
76
+                      {
77
+                        "name": "MYSQL_DATABASE",
78
+                        "value": "${MYSQL_DATABASE}"
79
+                      }
80
+                    ],
81
+                    "image": "mysql",
82
+                    "name": "mysql",
83
+                    "ports": [
84
+                      {
85
+                        "containerPort": 3306
86
+                      }
87
+                    ]
88
+                  }
89
+                ],
90
+                "version": "v1beta1"
91
+              }
92
+            },
93
+            "labels": {
94
+              "name": "mysql"
95
+            }
96
+          },
97
+          "replicaSelector": {
98
+            "name": "mysql"
99
+          },
100
+          "replicas": 1
101
+        },
102
+        "strategy": {
103
+          "type": "Recreate"
104
+        }
105
+      },
106
+      "triggers": [
107
+        {
108
+          "imageChangeParams": {
109
+            "automatic": true,
110
+            "containerNames": [
111
+              "mysql"
112
+            ],
113
+            "from": {
114
+              "name": "mysql"
115
+            },
116
+            "tag": "latest"
117
+          },
118
+          "type": "ImageChange"
119
+        },
120
+        {
121
+          "type": "ConfigChange"
122
+        }
123
+      ]
124
+    }
125
+  ]
126
+}
0 127
deleted file mode 100644
... ...
@@ -1,114 +0,0 @@
1
-{
2
-  "apiVersion": "v1beta1",
3
-  "kind": "Template",
4
-  "metadata": {
5
-    "annotations": {
6
-      "description": "This template creates a basic PostgreSQL database service",
7
-      "tags": "database,postgresql",
8
-      "iconClass" : "icon-postgresql"
9
-    },
10
-    "name": "postgresql"
11
-  },
12
-  "parameters": [
13
-    {
14
-      "description": "database username",
15
-      "from": "user[A-Z0-9]{3}",
16
-      "generate": "expression",
17
-      "name": "POSTGRESQL_USER"
18
-    },
19
-    {
20
-      "description": "database password",
21
-      "from": "[a-zA-Z0-9]{8}",
22
-      "generate": "expression",
23
-      "name": "POSTGRESQL_PASSWORD"
24
-    },
25
-    {
26
-      "description": "database name",
27
-      "name": "POSTGRESQL_DATABASE",
28
-      "value": "sampledb"
29
-    }
30
-  ],
31
-  "labels": {
32
-    "template": "postgresql-template"
33
-  },
34
-  "items": [
35
-    {
36
-      "apiVersion": "v1beta1",
37
-      "containerPort": 5432,
38
-      "id": "postgresql",
39
-      "kind": "Service",
40
-      "port": 5432,
41
-      "selector": {
42
-        "name": "postgresql"
43
-      }
44
-    },
45
-    {
46
-      "apiVersion": "v1beta1",
47
-      "kind": "DeploymentConfig",
48
-      "metadata": {
49
-        "name": "postgresql"
50
-      },
51
-      "template": {
52
-        "controllerTemplate": {
53
-          "podTemplate": {
54
-            "desiredState": {
55
-              "manifest": {
56
-                "containers": [
57
-                  {
58
-                    "env": [
59
-                      {
60
-                        "name": "POSTGRESQL_USER",
61
-                        "value": "${POSTGRESQL_USER}"
62
-                      },
63
-                      {
64
-                        "name": "POSTGRESQL_PASSWORD",
65
-                        "value": "${POSTGRESQL_PASSWORD}"
66
-                      },
67
-                      {
68
-                        "name": "POSTGRESQL_DATABASE",
69
-                        "value": "${POSTGRESQL_DATABASE}"
70
-                      }
71
-                    ],
72
-                    "image": "postgresql",
73
-                    "name": "postgresql",
74
-                    "ports": [
75
-                      {
76
-                        "containerPort": 5432
77
-                      }
78
-                    ]
79
-                  }
80
-                ],
81
-                "version": "v1beta1"
82
-              }
83
-            },
84
-            "labels": {
85
-              "name": "postgresql"
86
-            }
87
-          },
88
-          "replicaSelector": {
89
-            "name": "postgresql"
90
-          },
91
-          "replicas": 1
92
-        },
93
-        "strategy": {
94
-          "type": "Recreate"
95
-        }
96
-      },
97
-      "triggers": [
98
-        {
99
-          "imageChangeParams": {
100
-            "automatic": true,
101
-            "containerNames": [
102
-              "postgresql"
103
-            ],
104
-            "from": {
105
-              "name": "postgresql-92-centos7"
106
-            },
107
-            "tag": "latest"
108
-          },
109
-          "type": "ImageChange"
110
-        }
111
-      ]
112
-    }
113
-  ]
114
-}
115 1
deleted file mode 100644
... ...
@@ -1,114 +0,0 @@
1
-{
2
-  "apiVersion": "v1beta1",
3
-  "kind": "Template",
4
-  "metadata": {
5
-    "annotations": {
6
-      "description": "This template creates a basic PostgreSQL database service",
7
-      "tags": "database,postgresql",
8
-      "iconClass" : "icon-postgresql"
9
-    },
10
-    "name": "postgresql"
11
-  },
12
-  "parameters": [
13
-    {
14
-      "description": "database username",
15
-      "from": "user[A-Z0-9]{3}",
16
-      "generate": "expression",
17
-      "name": "POSTGRESQL_USER"
18
-    },
19
-    {
20
-      "description": "database password",
21
-      "from": "[a-zA-Z0-9]{8}",
22
-      "generate": "expression",
23
-      "name": "POSTGRESQL_PASSWORD"
24
-    },
25
-    {
26
-      "description": "database name",
27
-      "name": "POSTGRESQL_DATABASE",
28
-      "value": "sampledb"
29
-    }
30
-  ],
31
-  "labels": {
32
-    "template": "postgresql-template"
33
-  },
34
-  "items": [
35
-    {
36
-      "apiVersion": "v1beta1",
37
-      "containerPort": 5432,
38
-      "id": "postgresql",
39
-      "kind": "Service",
40
-      "port": 5432,
41
-      "selector": {
42
-        "name": "postgresql"
43
-      }
44
-    },
45
-    {
46
-      "apiVersion": "v1beta1",
47
-      "kind": "DeploymentConfig",
48
-      "metadata": {
49
-        "name": "postgresql"
50
-      },
51
-      "template": {
52
-        "controllerTemplate": {
53
-          "podTemplate": {
54
-            "desiredState": {
55
-              "manifest": {
56
-                "containers": [
57
-                  {
58
-                    "env": [
59
-                      {
60
-                        "name": "POSTGRESQL_USER",
61
-                        "value": "${POSTGRESQL_USER}"
62
-                      },
63
-                      {
64
-                        "name": "POSTGRESQL_PASSWORD",
65
-                        "value": "${POSTGRESQL_PASSWORD}"
66
-                      },
67
-                      {
68
-                        "name": "POSTGRESQL_DATABASE",
69
-                        "value": "${POSTGRESQL_DATABASE}"
70
-                      }
71
-                    ],
72
-                    "image": "postgresql",
73
-                    "name": "postgresql",
74
-                    "ports": [
75
-                      {
76
-                        "containerPort": 5432
77
-                      }
78
-                    ]
79
-                  }
80
-                ],
81
-                "version": "v1beta1"
82
-              }
83
-            },
84
-            "labels": {
85
-              "name": "postgresql"
86
-            }
87
-          },
88
-          "replicaSelector": {
89
-            "name": "postgresql"
90
-          },
91
-          "replicas": 1
92
-        },
93
-        "strategy": {
94
-          "type": "Recreate"
95
-        }
96
-      },
97
-      "triggers": [
98
-        {
99
-          "imageChangeParams": {
100
-            "automatic": true,
101
-            "containerNames": [
102
-              "postgresql"
103
-            ],
104
-            "from": {
105
-              "name": "postgresql-92-rhel7"
106
-            },
107
-            "tag": "latest"
108
-          },
109
-          "type": "ImageChange"
110
-        }
111
-      ]
112
-    }
113
-  ]
114
-}
115 1
new file mode 100644
... ...
@@ -0,0 +1,127 @@
0
+{
1
+  "apiVersion": "v1beta1",
2
+  "kind": "Template",
3
+  "metadata": {
4
+    "annotations": {
5
+      "description": "This template creates a basic PostgreSQL database service",
6
+      "tags": "database,postgresql",
7
+      "iconClass" : "icon-postgresql"
8
+    },
9
+    "name": "postgresql"
10
+  },
11
+  "parameters": [
12
+    {
13
+      "description": "database username",
14
+      "from": "user[A-Z0-9]{3}",
15
+      "generate": "expression",
16
+      "name": "POSTGRESQL_USER"
17
+    },
18
+    {
19
+      "description": "database password",
20
+      "from": "[a-zA-Z0-9]{8}",
21
+      "generate": "expression",
22
+      "name": "POSTGRESQL_PASSWORD"
23
+    },
24
+    {
25
+      "description": "database name",
26
+      "name": "POSTGRESQL_DATABASE",
27
+      "value": "sampledb"
28
+    }
29
+  ],
30
+  "labels": {
31
+    "template": "postgresql-template"
32
+  },
33
+  "items": [
34
+    {
35
+      "apiVersion": "v1beta3",
36
+      "kind": "Service",
37
+      "metadata": {
38
+        "name": "postgresql"
39
+      },
40
+      "spec": {
41
+        "ports": [
42
+          {
43
+            "name": "postgresql",
44
+            "port": 5432,
45
+            "protocol": "TCP",
46
+            "targetPort": 5432
47
+          }
48
+        ],
49
+        "selector": {
50
+          "name": "postgresql"
51
+        }
52
+      }
53
+    },
54
+    {
55
+      "apiVersion": "v1beta1",
56
+      "kind": "DeploymentConfig",
57
+      "metadata": {
58
+        "name": "postgresql"
59
+      },
60
+      "template": {
61
+        "controllerTemplate": {
62
+          "podTemplate": {
63
+            "desiredState": {
64
+              "manifest": {
65
+                "containers": [
66
+                  {
67
+                    "env": [
68
+                      {
69
+                        "name": "POSTGRESQL_USER",
70
+                        "value": "${POSTGRESQL_USER}"
71
+                      },
72
+                      {
73
+                        "name": "POSTGRESQL_PASSWORD",
74
+                        "value": "${POSTGRESQL_PASSWORD}"
75
+                      },
76
+                      {
77
+                        "name": "POSTGRESQL_DATABASE",
78
+                        "value": "${POSTGRESQL_DATABASE}"
79
+                      }
80
+                    ],
81
+                    "image": "postgresql",
82
+                    "name": "postgresql",
83
+                    "ports": [
84
+                      {
85
+                        "containerPort": 5432
86
+                      }
87
+                    ]
88
+                  }
89
+                ],
90
+                "version": "v1beta1"
91
+              }
92
+            },
93
+            "labels": {
94
+              "name": "postgresql"
95
+            }
96
+          },
97
+          "replicaSelector": {
98
+            "name": "postgresql"
99
+          },
100
+          "replicas": 1
101
+        },
102
+        "strategy": {
103
+          "type": "Recreate"
104
+        }
105
+      },
106
+      "triggers": [
107
+        {
108
+          "imageChangeParams": {
109
+            "automatic": true,
110
+            "containerNames": [
111
+              "postgresql"
112
+            ],
113
+            "from": {
114
+              "name": "postgresql"
115
+            },
116
+            "tag": "latest"
117
+          },
118
+          "type": "ImageChange"
119
+        },
120
+        {
121
+          "type": "ConfigChange"
122
+        }
123
+      ]
124
+    }
125
+  ]
126
+}
... ...
@@ -82,12 +82,9 @@ func TestExampleObjectSchemas(t *testing.T) {
82 82
 			"image-streams-rhel7":   &imageapi.ImageStreamList{},
83 83
 		},
84 84
 		"../examples/db-templates": {
85
-			"mysql-rhel7-template":        &templateapi.Template{},
86
-			"postgresql-rhel7-template":   &templateapi.Template{},
87
-			"mongodb-rhel7-template":      &templateapi.Template{},
88
-			"mysql-centos7-template":      &templateapi.Template{},
89
-			"postgresql-centos7-template": &templateapi.Template{},
90
-			"mongodb-centos7-template":    &templateapi.Template{},
85
+			"mysql-template":      &templateapi.Template{},
86
+			"postgresql-template": &templateapi.Template{},
87
+			"mongodb-template":    &templateapi.Template{},
91 88
 		},
92 89
 		"../test/integration/fixtures": {
93 90
 			"test-deployment-config":        &deployapi.DeploymentConfig{},
... ...
@@ -6,7 +6,7 @@
6 6
       "apiVersion": "v1beta1",
7 7
       "kind": "ImageStream",
8 8
       "metadata": {
9
-        "name": "ruby-20-centos7"
9
+        "name": "ruby"
10 10
       },
11 11
       "spec": {
12 12
         "dockerImageRepository": "openshift/ruby-20-centos7",
... ...
@@ -27,7 +27,7 @@
27 27
       "apiVersion": "v1beta1",
28 28
       "kind": "ImageStream",
29 29
       "metadata": {
30
-        "name": "nodejs-010-centos7"
30
+        "name": "nodejs"
31 31
       },
32 32
       "spec": {
33 33
         "dockerImageRepository": "openshift/nodejs-010-centos7",
... ...
@@ -48,7 +48,7 @@
48 48
       "apiVersion": "v1beta1",
49 49
       "kind": "ImageStream",
50 50
       "metadata": {
51
-        "name": "perl-516-centos7"
51
+        "name": "perl"
52 52
       },
53 53
       "spec": {
54 54
         "dockerImageRepository": "openshift/perl-516-centos7",
... ...
@@ -69,7 +69,7 @@
69 69
       "apiVersion": "v1beta1",
70 70
       "kind": "ImageStream",
71 71
       "metadata": {
72
-        "name": "python-33-centos7"
72
+        "name": "python"
73 73
       },
74 74
       "spec": {
75 75
         "dockerImageRepository": "openshift/python-33-centos7",
... ...
@@ -90,7 +90,7 @@
90 90
       "apiVersion": "v1beta1",
91 91
       "kind": "ImageStream",
92 92
       "metadata": {
93
-        "name": "wildfly-8-centos"
93
+        "name": "wildfly"
94 94
       },
95 95
       "spec": {
96 96
         "dockerImageRepository": "openshift/wildfly-8-centos",
... ...
@@ -111,30 +111,45 @@
111 111
       "apiVersion": "v1beta1",
112 112
       "kind": "ImageStream",
113 113
       "metadata": {
114
-        "name": "mysql-55-centos7"
114
+        "name": "mysql"
115 115
       },
116 116
       "spec": {
117
-        "dockerImageRepository": "openshift/mysql-55-centos7"
117
+        "dockerImageRepository": "openshift/mysql-55-centos7",
118
+        "tags": [
119
+          {
120
+            "name":"latest"
121
+          }
122
+        ]
118 123
       }
119 124
     },
120 125
     {
121 126
       "apiVersion": "v1beta1",
122 127
       "kind": "ImageStream",
123 128
       "metadata": {
124
-        "name": "postgresql-92-centos7"
129
+        "name": "postgresql"
125 130
       },
126 131
       "spec": {
127
-        "dockerImageRepository": "openshift/postgresql-92-centos7"
132
+        "dockerImageRepository": "openshift/postgresql-92-centos7",
133
+        "tags": [
134
+          {
135
+            "name":"latest"
136
+          }
137
+        ]
128 138
       }
129 139
     },
130 140
     {
131 141
       "apiVersion": "v1beta1",
132 142
       "kind": "ImageStream",
133 143
       "metadata": {
134
-        "name": "mongodb-24-centos7"
144
+        "name": "mongodb"
135 145
       },
136 146
       "spec": {
137
-        "dockerImageRepository": "openshift/mongodb-24-centos7"
147
+        "dockerImageRepository": "openshift/mongodb-24-centos7",
148
+        "tags": [
149
+          {
150
+            "name":"latest"
151
+          }
152
+        ]
138 153
       }
139 154
     }
140 155
   ]
... ...
@@ -6,7 +6,7 @@
6 6
       "apiVersion": "v1beta1",
7 7
       "kind": "ImageStream",
8 8
       "metadata": {
9
-        "name": "ruby-20-rhel7"
9
+        "name": "ruby"
10 10
       },
11 11
       "spec": {
12 12
         "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/ruby-20-rhel7",
... ...
@@ -27,7 +27,7 @@
27 27
       "apiVersion": "v1beta1",
28 28
       "kind": "ImageStream",
29 29
       "metadata": {
30
-        "name": "nodejs-010-rhel7"
30
+        "name": "nodejs"
31 31
       },
32 32
       "spec": {
33 33
         "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/nodejs-010-rhel7",
... ...
@@ -48,7 +48,7 @@
48 48
       "apiVersion": "v1beta1",
49 49
       "kind": "ImageStream",
50 50
       "metadata": {
51
-        "name": "perl-516-rhel7"
51
+        "name": "perl"
52 52
       },
53 53
       "spec": {
54 54
         "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/perl-516-rhel7",
... ...
@@ -69,7 +69,7 @@
69 69
       "apiVersion": "v1beta1",
70 70
       "kind": "ImageStream",
71 71
       "metadata": {
72
-        "name": "python-33-rhel7"
72
+        "name": "python"
73 73
       },
74 74
       "spec": {
75 75
         "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/python-33-rhel7",
... ...
@@ -90,30 +90,45 @@
90 90
       "apiVersion": "v1beta1",
91 91
       "kind": "ImageStream",
92 92
       "metadata": {
93
-        "name": "mysql-55-rhel7"
93
+        "name": "mysql"
94 94
       },
95 95
       "spec": {
96
-        "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/mysql-55-rhel7"
96
+        "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/mysql-55-rhel7",
97
+        "tags": [
98
+          {
99
+            "name":"latest"
100
+          }
101
+        ]
97 102
       }
98 103
     },
99 104
     {
100 105
       "apiVersion": "v1beta1",
101 106
       "kind": "ImageStream",
102 107
       "metadata": {
103
-        "name": "postgresql-92-rhel7"
108
+        "name": "postgresql"
104 109
       },
105 110
       "spec": {
106
-        "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/postgresql-92-rhel7"
111
+        "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/postgresql-92-rhel7",
112
+        "tags": [
113
+          {
114
+            "name":"latest"
115
+          }
116
+        ]
107 117
       }
108 118
     },
109 119
     {
110 120
       "apiVersion": "v1beta1",
111 121
       "kind": "ImageStream",
112 122
       "metadata": {
113
-        "name": "mongodb-24-rhel7"
123
+        "name": "mongodb"
114 124
       },
115 125
       "spec": {
116
-        "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/mongodb-24-rhel7"
126
+        "dockerImageRepository": "registry.access.redhat.com/openshift3_beta/mongodb-24-rhel7",
127
+        "tags": [
128
+          {
129
+            "name":"latest"
130
+          }
131
+        ]
117 132
       }
118 133
     }
119 134
   ]
... ...
@@ -2,13 +2,23 @@
2 2
   "apiVersion": "v1beta1",
3 3
   "items": [
4 4
     {
5
-      "apiVersion": "v1beta1",
6
-      "containerPort": 8080,
7
-      "id": "frontend",
5
+      "apiVersion": "v1beta3",
8 6
       "kind": "Service",
9
-      "port": 5432,
10
-      "selector": {
7
+      "metadata": {
11 8
         "name": "frontend"
9
+      },
10
+      "spec": {
11
+        "ports": [
12
+          {
13
+            "name": "web",
14
+            "port": 5432,
15
+            "protocol": "TCP",
16
+            "targetPort": 8080
17
+          }
18
+        ],
19
+        "selector": {
20
+          "name": "frontend"
21
+        }
12 22
       }
13 23
     },
14 24
     {
... ...
@@ -74,10 +84,9 @@
74 74
               }
75 75
             ],
76 76
             "exposeDockerSocket": true,
77
-            "customStrategy": {
78
-              "from": {
79
-                "name":"origin-custom-docker-builder"
80
-              }
77
+            "from": {
78
+              "kind": "ImageStreamTag",
79
+              "name": "origin-custom-docker-builder:latest"
81 80
             }
82 81
           },
83 82
           "type": "Custom"
... ...
@@ -179,13 +188,23 @@
179 179
       ]
180 180
     },
181 181
     {
182
-      "apiVersion": "v1beta1",
183
-      "containerPort": 3306,
184
-      "id": "database",
182
+      "apiVersion": "v1beta3",
185 183
       "kind": "Service",
186
-      "port": 5434,
187
-      "selector": {
184
+      "metadata": {
188 185
         "name": "database"
186
+      },
187
+      "spec": {
188
+        "ports": [
189
+          {
190
+            "name": "db",
191
+            "port": 5434,
192
+            "protocol": "TCP",
193
+            "targetPort": 3306
194
+          }
195
+        ],
196
+        "selector": {
197
+          "name": "database"
198
+        }
189 199
       }
190 200
     },
191 201
     {
... ...
@@ -2,13 +2,23 @@
2 2
   "apiVersion": "v1beta1",
3 3
   "items": [
4 4
     {
5
-      "apiVersion": "v1beta1",
6
-      "containerPort": 8080,
7
-      "id": "frontend",
5
+      "apiVersion": "v1beta3",
8 6
       "kind": "Service",
9
-      "port": 5432,
10
-      "selector": {
7
+      "metadata": {
11 8
         "name": "frontend"
9
+      },
10
+      "spec": {
11
+        "ports": [
12
+          {
13
+            "name": "web",
14
+            "port": 5432,
15
+            "protocol": "TCP",
16
+            "targetPort": 8080
17
+          }
18
+        ],
19
+        "selector": {
20
+          "name": "frontend"
21
+        }
12 22
       }
13 23
     },
14 24
     {
... ...
@@ -69,7 +79,8 @@
69 69
           "type": "Docker",
70 70
           "dockerStrategy": {
71 71
             "from": {
72
-              "name":"ruby-20-centos7"
72
+              "kind": "ImageStreamTag",
73
+              "name":"ruby-20-centos7:latest"
73 74
             }
74 75
           }
75 76
         }
... ...
@@ -170,13 +181,23 @@
170 170
       ]
171 171
     },
172 172
     {
173
-      "apiVersion": "v1beta1",
174
-      "containerPort": 3306,
175
-      "id": "database",
173
+      "apiVersion": "v1beta3",
176 174
       "kind": "Service",
177
-      "port": 5434,
178
-      "selector": {
175
+      "metadata": {
179 176
         "name": "database"
177
+      },
178
+      "spec": {
179
+        "ports": [
180
+          {
181
+            "name": "db",
182
+            "port": 5434,
183
+            "protocol": "TCP",
184
+            "targetPort": 3306
185
+          }
186
+        ],
187
+        "selector": {
188
+          "name": "database"
189
+        }
180 190
       }
181 191
     },
182 192
     {
... ...
@@ -2,13 +2,23 @@
2 2
   "apiVersion": "v1beta1",
3 3
   "items": [
4 4
     {
5
-      "apiVersion": "v1beta1",
6
-      "containerPort": 8080,
7
-      "id": "frontend",
5
+      "apiVersion": "v1beta3",
8 6
       "kind": "Service",
9
-      "port": 5432,
10
-      "selector": {
7
+      "metadata": {
11 8
         "name": "frontend"
9
+      },
10
+      "spec": {
11
+        "ports": [
12
+          {
13
+            "name": "web",
14
+            "port": 5432,
15
+            "protocol": "TCP",
16
+            "targetPort": 8080
17
+          }
18
+        ],
19
+        "selector": {
20
+          "name": "frontend"
21
+        }
12 22
       }
13 23
     },
14 24
     {
... ...
@@ -203,13 +213,23 @@
203 203
       ]
204 204
     },
205 205
     {
206
-      "apiVersion": "v1beta1",
207
-      "containerPort": 3306,
208
-      "id": "database",
206
+      "apiVersion": "v1beta3",
209 207
       "kind": "Service",
210
-      "port": 5434,
211
-      "selector": {
208
+      "metadata": {
212 209
         "name": "database"
210
+      },
211
+      "spec": {
212
+        "ports": [
213
+          {
214
+            "name": "db",
215
+            "port": 5434,
216
+            "protocol": "TCP",
217
+            "targetPort": 3306
218
+          }
219
+        ],
220
+        "selector": {
221
+          "name": "database"
222
+        }
213 223
       }
214 224
     },
215 225
     {
... ...
@@ -296,24 +296,24 @@ osc delete pod $(osc get pod | grep docker-registry-1 | awk '{print $1}')
296 296
 osc delete imageStreams test
297 297
 [ -z "$(osc get imageStreams test -t "{{.status.dockerImageRepository}}")" ]
298 298
 osc create -f examples/image-streams/image-streams-centos7.json
299
-[ -n "$(osc get imageStreams ruby-20-centos7 -t "{{.status.dockerImageRepository}}")" ]
300
-[ -n "$(osc get imageStreams nodejs-010-centos7 -t "{{.status.dockerImageRepository}}")" ]
301
-[ -n "$(osc get imageStreams wildfly-8-centos -t "{{.status.dockerImageRepository}}")" ]
302
-[ -n "$(osc get imageStreams mysql-55-centos7 -t "{{.status.dockerImageRepository}}")" ]
303
-[ -n "$(osc get imageStreams postgresql-92-centos7 -t "{{.status.dockerImageRepository}}")" ]
304
-[ -n "$(osc get imageStreams mongodb-24-centos7 -t "{{.status.dockerImageRepository}}")" ]
305
-osc delete imageStreams ruby-20-centos7
306
-osc delete imageStreams nodejs-010-centos7
307
-osc delete imageStreams wildfly-8-centos
308
-osc delete imageStreams mysql-55-centos7
309
-osc delete imageStreams postgresql-92-centos7
310
-osc delete imageStreams mongodb-24-centos7
311
-[ -z "$(osc get imageStreams ruby-20-centos7 -t "{{.status.dockerImageRepository}}")" ]
312
-[ -z "$(osc get imageStreams nodejs-010-centos7 -t "{{.status.dockerImageRepository}}")" ]
313
-[ -z "$(osc get imageStreams wildfly-8-centos -t "{{.status.dockerImageRepository}}")" ]
314
-[ -z "$(osc get imageStreams mysql-55-centos7 -t "{{.status.dockerImageRepository}}")" ]
315
-[ -z "$(osc get imageStreams postgresql-92-centos7 -t "{{.status.dockerImageRepository}}")" ]
316
-[ -z "$(osc get imageStreams mongodb-24-centos7 -t "{{.status.dockerImageRepository}}")" ]
299
+[ -n "$(osc get imageStreams ruby -t "{{.status.dockerImageRepository}}")" ]
300
+[ -n "$(osc get imageStreams nodejs -t "{{.status.dockerImageRepository}}")" ]
301
+[ -n "$(osc get imageStreams wildfly -t "{{.status.dockerImageRepository}}")" ]
302
+[ -n "$(osc get imageStreams mysql -t "{{.status.dockerImageRepository}}")" ]
303
+[ -n "$(osc get imageStreams postgresql -t "{{.status.dockerImageRepository}}")" ]
304
+[ -n "$(osc get imageStreams mongodb -t "{{.status.dockerImageRepository}}")" ]
305
+osc delete imageStreams ruby
306
+osc delete imageStreams nodejs
307
+osc delete imageStreams wildfly
308
+osc delete imageStreams mysql
309
+osc delete imageStreams postgresql
310
+osc delete imageStreams mongodb
311
+[ -z "$(osc get imageStreams ruby -t "{{.status.dockerImageRepository}}")" ]
312
+[ -z "$(osc get imageStreams nodejs -t "{{.status.dockerImageRepository}}")" ]
313
+[ -z "$(osc get imageStreams wildfly -t "{{.status.dockerImageRepository}}")" ]
314
+[ -z "$(osc get imageStreams mysql -t "{{.status.dockerImageRepository}}")" ]
315
+[ -z "$(osc get imageStreams postgresql -t "{{.status.dockerImageRepository}}")" ]
316
+[ -z "$(osc get imageStreams mongodb -t "{{.status.dockerImageRepository}}")" ]
317 317
 echo "imageStreams: ok"
318 318
 
319 319
 osc create -f test/integration/fixtures/test-image-stream.json