diff --git a/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/domain/KnownHost.kt b/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/domain/KnownHost.kt index fa51e38..443bd3a 100644 --- a/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/domain/KnownHost.kt +++ b/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/domain/KnownHost.kt @@ -7,7 +7,10 @@ package org.domaindrivenarchitecture.provs.desktop.domain */ typealias HostKey = String -open class KnownHost protected constructor(val hostName: String, val hostKeys: List) { +open class KnownHost protected constructor( + val hostName: String, + val hostKeys: List +) { companion object { val GITHUB = KnownHost( "github.com", listOf( diff --git a/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/domain/KnownHostService.kt b/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/domain/KnownHostService.kt index 77e6e0f..4ceb6bb 100644 --- a/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/domain/KnownHostService.kt +++ b/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/domain/KnownHostService.kt @@ -6,8 +6,6 @@ import org.domaindrivenarchitecture.provs.framework.ubuntu.keys.base.addKnownHos fun Prov.addKnownHosts(knownHosts: List = KnownHost.values()) = task { for (knownHost in knownHosts) { - with(knownHost) { - addKnownHost(hostName, hostKeys, verifyKeys = true) - } + addKnownHost(knownHost.hostName, knownHost.hostKeys, verifyKeys = true) } } \ No newline at end of file diff --git a/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/infrastructure/DevOps.kt b/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/infrastructure/DevOps.kt index 178f201..50c4563 100644 --- a/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/infrastructure/DevOps.kt +++ b/src/main/kotlin/org/domaindrivenarchitecture/provs/desktop/infrastructure/DevOps.kt @@ -15,10 +15,6 @@ fun Prov.installDevOps() = task { installTerraform() installKubectlAndTools() installYq() - // TODO: the can be removed - installAwsCredentials() - // TODO: the can be removed - installDevOpsFolder() } @@ -169,13 +165,3 @@ fun awsCredentials(id: String, key: String): String { aws_secret_access_key = $key """.trimIndent() } - -fun Prov.installDevOpsFolder(): ProvResult = task { - - val dir = "~/.devops/" - - if (!checkDir(dir)) { - createDirs(dir) - } - -}