Skip to content

Commit e910df1

Browse files
author
olegs-codefresh
authored
support passing secret-yaml as context to install-chart cmd
1 parent dd71041 commit e910df1

File tree

6 files changed

+21
-5
lines changed

6 files changed

+21
-5
lines changed

examples/secret-yaml.yaml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
apiVersion: v1
2+
# Using this example you can install helm mongodb chart and set the service type as LoadBalancer instaed default ClusterIp
3+
# https://github.com/kubernetes/charts/blob/master/stable/mongodb/values.yaml
4+
kind: context
5+
owner: account
6+
metadata:
7+
name: helm-mongo-secret-values
8+
spec:
9+
type: secret-yaml
10+
data:
11+
# All the values will be encrypted
12+
serviceType: LoadBalancer
13+
image: mongo
14+
type:
15+
- "encrypted"

lib/interface/cli/commands/context/create.cmd.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ const command = new Command({
1717
})
1818
.positional('type', {
1919
describe: 'Type of the context',
20-
choices: ['config', 'secret', 'helm-repository', 'plain-yaml'],
20+
choices: ['config', 'secret', 'helm-repository', 'plain-yaml', 'secret-yaml'],
2121
})
2222
.option('owner', {
2323
describe: 'Owner of the context',

lib/interface/cli/commands/context/get.cmd.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ const command = new Command({
1919
})
2020
.option('type', {
2121
describe: 'Specific type of context',
22-
choices: ['config', 'secret', 'helm-repository'],
22+
choices: ['config', 'secret', 'helm-repository', 'plain-yaml', 'secret-yaml'],
2323
})
2424
.option('owner', {
2525
describe: 'Owner of the context',

lib/interface/cli/commands/pipeline/dynamic/install-chart.cmd.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ const install = new Command({
5858
name: argv.name,
5959
repository: argv.repository,
6060
version: argv.version,
61-
values: argv.values,
61+
values: argv.context,
6262
tillerNamespace: argv.tillerNamespace,
6363
});
6464
console.log(`Started with id: ${workflowId}`);

lib/logic/api/helm.js

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@ const { getContextByName } = require('./context');
66

77
const SUPPORTED_TYPES = [
88
'plain-yaml',
9+
'secret-yaml',
910
];
1011

1112

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "codefresh",
3-
"version": "0.5.8",
3+
"version": "0.5.9",
44
"description": "Codefresh command line utility",
55
"main": "index.js",
66
"preferGlobal": true,
@@ -21,7 +21,6 @@
2121
"scripts": "lib/**/*.js"
2222
},
2323
"dependencies": {
24-
"firebase": "git+https://github.com/codefresh-io/firebase.git#80b2ed883ff281cd67b53bd0f6a0bbd6f330fed5",
2524
"@codefresh-io/docker-reference": "^0.0.5",
2625
"bluebird": "^3.5.1",
2726
"cf-errors": "^0.1.11",
@@ -30,6 +29,7 @@
3029
"columnify": "^1.5.4",
3130
"debug": "^3.1.0",
3231
"filesize": "^3.5.11",
32+
"firebase": "git+https://github.com/codefresh-io/firebase.git#80b2ed883ff281cd67b53bd0f6a0bbd6f330fed5",
3333
"js-yaml": "^3.10.0",
3434
"jsonwebtoken": "^8.1.0",
3535
"kefir": "^3.8.0",

0 commit comments

Comments
 (0)