Skip to content

Commit

Permalink
refactor(k8s): rename "local" build mode to "local-docker"
Browse files Browse the repository at this point in the history
  • Loading branch information
edvald committed Jun 13, 2019
1 parent a5ed2cf commit 55d9cec
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 8 deletions.
2 changes: 1 addition & 1 deletion docs/reference/providers/kubernetes.md
Original file line number Diff line number Diff line change
Expand Up @@ -774,7 +774,7 @@ variables: {}
environments:
- providers:
- environments:
buildMode: local
buildMode: local-docker
defaultHostname:
defaultUsername:
forceSsl: false
Expand Down
2 changes: 1 addition & 1 deletion docs/reference/providers/local-kubernetes.md
Original file line number Diff line number Diff line change
Expand Up @@ -699,7 +699,7 @@ variables: {}
environments:
- providers:
- environments:
buildMode: local
buildMode: local-docker
defaultHostname:
defaultUsername:
forceSsl: false
Expand Down
6 changes: 3 additions & 3 deletions garden-service/src/plugins/kubernetes/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ interface KubernetesStorage {
sync: KubernetesStorageSpec
}

export type ContainerBuildMode = "local" | "cluster-docker" | "kaniko"
export type ContainerBuildMode = "local-docker" | "cluster-docker" | "kaniko"

export interface KubernetesBaseConfig extends ProviderConfig {
buildMode: ContainerBuildMode
Expand Down Expand Up @@ -220,8 +220,8 @@ const tlsCertificateSchema = Joi.object()
export const kubernetesConfigBase = providerConfigBaseSchema
.keys({
buildMode: Joi.string()
.allow("local", "cluster-docker", "kaniko")
.default("local")
.allow("local-docker", "cluster-docker", "kaniko")
.default("local-docker")
.description(deline`
Choose the mechanism used to build containers before deploying. By default it uses the local docker, but you
can set it to 'cluster-docker' or 'kaniko' to sync files to a remote docker daemon, installed in the cluster,
Expand Down
4 changes: 2 additions & 2 deletions garden-service/src/plugins/kubernetes/container/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ const getRemoteBuildStatus: BuildStatusHandler = async (params) => {
}

const buildStatusHandlers: { [mode in ContainerBuildMode]: BuildStatusHandler } = {
"local": getLocalBuildStatus,
"local-docker": getLocalBuildStatus,
"cluster-docker": getRemoteBuildStatus,
"kaniko": getRemoteBuildStatus,
}
Expand Down Expand Up @@ -248,7 +248,7 @@ interface BuilderExecParams {
}

const buildHandlers: { [mode in ContainerBuildMode]: BuildHandler } = {
"local": localBuild,
"local-docker": localBuild,
"cluster-docker": remoteBuild,
"kaniko": remoteBuild,
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ const ports = [{

const basicConfig: KubernetesConfig = {
name: "kubernetes",
buildMode: "local",
buildMode: "local-docker",
context: "my-cluster",
defaultHostname: "my.domain.com",
deploymentRegistry: {
Expand Down

0 comments on commit 55d9cec

Please sign in to comment.