Skip to content

Commit

Permalink
fix(k8s): make sure Helm client is initialized on startup
Browse files Browse the repository at this point in the history
  • Loading branch information
edvald committed Oct 28, 2018
1 parent b86c463 commit f1bf4bd
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions garden-service/src/plugins/kubernetes/init.ts
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ async function prepareNamespaces({ ctx }: GetEnvironmentStatusParams) {
])
}

export async function getRemoteEnvironmentStatus({ ctx }: GetEnvironmentStatusParams) {
export async function getRemoteEnvironmentStatus({ ctx, logEntry }: GetEnvironmentStatusParams) {
const loggedIn = await getLoginStatus({ ctx })

if (!loggedIn) {
Expand All @@ -76,18 +76,20 @@ export async function getRemoteEnvironmentStatus({ ctx }: GetEnvironmentStatusPa
}

await prepareNamespaces({ ctx })
await helm(ctx.provider, logEntry, "init", "--client-only")

return {
ready: true,
needUserInput: false,
}
}

export async function getLocalEnvironmentStatus({ ctx }: GetEnvironmentStatusParams) {
export async function getLocalEnvironmentStatus({ ctx, logEntry }: GetEnvironmentStatusParams) {
let ready = true
let needUserInput = false

await prepareNamespaces({ ctx })
await helm(ctx.provider, logEntry, "init", "--client-only")

// TODO: check if mkcert has been installed
// TODO: check if all certs have been generated
Expand Down

0 comments on commit f1bf4bd

Please sign in to comment.