remove uberjar folder and remove tests for now
This commit is contained in:
parent
303f7ae5f2
commit
74f4a29289
13 changed files with 0 additions and 302 deletions
|
@ -1,30 +0,0 @@
|
|||
{:input {:user :k8s
|
||||
:external-ip "95.217.221.140"
|
||||
:fqdn "cloud.test.meissa-gmbh.de"
|
||||
:cert-manager :letsencrypt-staging-issuer
|
||||
:db-user-password "test1234"
|
||||
:admin-user "root"
|
||||
:admin-password "test1234"
|
||||
:storage-size 50
|
||||
:restic-repository "test4321"
|
||||
:aws-access-key-id "10"
|
||||
:aws-secret-access-key "secret"
|
||||
:restic-password "test4321"}
|
||||
:expected {:meissa-cloud
|
||||
{:user :k8s
|
||||
:backup {:restic-repository "test4321"
|
||||
:aws-access-key-id "10"
|
||||
:aws-secret-access-key "secret"
|
||||
:restic-password "test4321"}
|
||||
:cloud {:fqdn "cloud.test.meissa-gmbh.de"
|
||||
:secret-name "cloud-test-meissa-gmbh-de"
|
||||
:cluster-issuer "letsencrypt-staging-issuer"
|
||||
:db-name "cloud"
|
||||
:db-user-password "test1234"
|
||||
:db-user-name "cloud"
|
||||
:admin-user "root"
|
||||
:admin-password "test1234"
|
||||
:storage-size "50"}
|
||||
:postgres {:db-user-password "test1234"
|
||||
:db-user-name "cloud"}}}
|
||||
}
|
|
@ -1,30 +0,0 @@
|
|||
{:input {:user :k8s
|
||||
:external-ip "95.217.221.140"
|
||||
:fqdn "cloud.test.meissa-gmbh.de"
|
||||
:cert-manager :letsencrypt-staging-issuer
|
||||
:db-user-password "test1234"
|
||||
:admin-user "root"
|
||||
:admin-password "test1234"
|
||||
:storage-size 50
|
||||
:restic-repository "cloud"
|
||||
:aws-access-key-id "10"
|
||||
:aws-secret-access-key "secret"
|
||||
:restic-password "test4321"}
|
||||
:expected {:user :k8s, :k8s {:external-ip "95.217.221.140"},
|
||||
:cert-manager :letsencrypt-staging-issuer}}
|
||||
|
||||
{:input {:user :k8s
|
||||
:external-ip "95.217.221.140"
|
||||
:fqdn "cloud.test.meissa-gmbh.de"
|
||||
:cert-manager :letsencrypt-staging-issuer
|
||||
:db-user-password "test1234"
|
||||
:admin-user "root"
|
||||
:admin-password "test1234"
|
||||
:storage-size 50
|
||||
:restic-repository "cloud"
|
||||
:aws-access-key-id "10"
|
||||
:aws-secret-access-key "secret"
|
||||
:restic-password "test4321"
|
||||
:u18-04 true}
|
||||
:expected {:user :k8s, :k8s {:external-ip "95.217.221.140", :u18-04 true}
|
||||
:cert-manager :letsencrypt-staging-issuer}}
|
|
@ -1,14 +0,0 @@
|
|||
{:input {:user :k8s
|
||||
:external-ip "95.217.221.140"
|
||||
:fqdn "cloud.test.meissa-gmbh.de"
|
||||
:cert-manager :letsencrypt-staging-issuer
|
||||
:db-user-password "test1234"
|
||||
:admin-user "root"
|
||||
:admin-password "test1234"
|
||||
:storage-size 50
|
||||
:restic-repository "test4321"
|
||||
:aws-access-key-id "10"
|
||||
:aws-secret-access-key "secret"
|
||||
:restic-password "test4321"}
|
||||
:expected true
|
||||
}
|
|
@ -1,14 +0,0 @@
|
|||
{:input {:user :k8s
|
||||
:external-ip "95.217.221.140"
|
||||
:fqdn "cloud.test.meissa-gmbh.de"
|
||||
:cert-manager :letsencrypt-staging-issuer
|
||||
:db-user-password "test-1234"
|
||||
:admin-user "root"
|
||||
:admin-password "test1234"
|
||||
:storage-size 50
|
||||
:restic-repository "test4321"
|
||||
:aws-access-key-id "10"
|
||||
:aws-secret-access-key "secret"
|
||||
:restic-password "test4321"}
|
||||
:expected false
|
||||
}
|
|
@ -1,14 +0,0 @@
|
|||
{:input {:user :k8s
|
||||
:external-ip "95.217.221.140"
|
||||
:fqdn "cloud.test.meissa-gmbh.de"
|
||||
:cert-manager :letsencrypt-staging-issuer
|
||||
:db-user-password "test1234"
|
||||
:admin-user "root"
|
||||
:admin-password "test1234"
|
||||
:storage-size 50
|
||||
:restic-repository "test4321"
|
||||
:aws-access-key-id "1$0"
|
||||
:aws-secret-access-key "secret"
|
||||
:restic-password "test4321"}
|
||||
:expected false
|
||||
}
|
|
@ -1,31 +0,0 @@
|
|||
(ns meissa.pallet.meissa-nextcloud.app-test
|
||||
(:require
|
||||
[clojure.test :refer :all]
|
||||
[schema.core :as s]
|
||||
[meissa.pallet.meissa-nextcloud.app :as sut]))
|
||||
|
||||
(s/set-fn-validation! true)
|
||||
|
||||
(s/def test-convention-conf
|
||||
{:user :k8s
|
||||
:external-ip "12.121.111.121"
|
||||
:fqdn "some.domain.de"
|
||||
:cert-manager :letsencrypt-staging-issuer
|
||||
:db-user-password "test1234"
|
||||
:admin-user "root"
|
||||
:admin-password "test1234"
|
||||
:storage-size 50
|
||||
:restic-repository "nextcloud"
|
||||
:aws-access-key-id "10"
|
||||
:aws-secret-access-key "secret"
|
||||
:restic-password "test4321"})
|
||||
|
||||
(deftest app-config
|
||||
(testing
|
||||
"test plan-def"
|
||||
(is (map? (sut/app-configuration-resolved test-convention-conf)))))
|
||||
|
||||
(deftest plan-def
|
||||
(testing
|
||||
"test plan-def"
|
||||
(is (map? sut/with-nextcloud))))
|
|
@ -1,20 +0,0 @@
|
|||
(ns meissa.pallet.meissa-cloud.convention.bash-php-test
|
||||
(:require
|
||||
[clojure.test :refer :all]
|
||||
[meissa.pallet.meissa-cloud.convention.bash-php :as sut]))
|
||||
|
||||
|
||||
(deftest test-it
|
||||
(is (= false
|
||||
(sut/bash-php-env-string? 4)))
|
||||
(is (= false
|
||||
(sut/bash-php-env-string? "hal-lo")))
|
||||
(is (= false
|
||||
(sut/bash-php-env-string? "hal--lo")))
|
||||
(is (= false
|
||||
(sut/bash-php-env-string? "hal\\lo")))
|
||||
(is (= true
|
||||
(sut/bash-php-env-string? "test")))
|
||||
(is (= true
|
||||
(sut/bash-php-env-string? "test123")))
|
||||
)
|
|
@ -1,22 +0,0 @@
|
|||
(ns meissa.pallet.meissa-cloud.convention.bash-test
|
||||
(:require
|
||||
[clojure.test :refer :all]
|
||||
[meissa.pallet.meissa-cloud.convention.bash :as sut]))
|
||||
|
||||
|
||||
(deftest test-it
|
||||
(is (= false
|
||||
(sut/bash-env-string? 4)))
|
||||
(is (= false
|
||||
(sut/bash-env-string? "1$0")))
|
||||
(is (= false
|
||||
(sut/bash-env-string? "'hallo")))
|
||||
(is (= false
|
||||
(sut/bash-env-string? "hallo\"")))
|
||||
(is (= false
|
||||
(sut/bash-env-string? "hall$o")))
|
||||
(is (= true
|
||||
(sut/bash-env-string? "test")))
|
||||
(is (= true
|
||||
(sut/bash-env-string? "test123")))
|
||||
)
|
|
@ -1,18 +0,0 @@
|
|||
(ns meissa.pallet.meissa-cloud.convention-test
|
||||
(:require
|
||||
[clojure.test :refer :all]
|
||||
[data-test :refer :all]
|
||||
[meissa.pallet.meissa-cloud.convention :as sut]
|
||||
[clojure.spec.alpha :as sp]))
|
||||
|
||||
(defdatatest should-generate-infra-for-convention [input expected]
|
||||
(is (= expected
|
||||
(sut/infra-configuration input))))
|
||||
|
||||
(defdatatest should-generate-k8s-convention [input expected]
|
||||
(is (= expected
|
||||
(sut/k8s-convention-configuration input))))
|
||||
|
||||
(defdatatest should-validate-input [input expected]
|
||||
(is (= expected
|
||||
(sp/valid? sut/cloud-convention-resolved? input))))
|
|
@ -1,2 +0,0 @@
|
|||
{:existing [{:node-name "localhost"
|
||||
:node-ip "127.0.0.1"}]}
|
|
@ -1,50 +0,0 @@
|
|||
<configuration scan="true" scanPeriod="1 seconds" debug="false">
|
||||
<appender name="CONSOLE" class="ch.qos.logback.core.ConsoleAppender">
|
||||
<encoder>
|
||||
<pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger{36} - %msg%n</pattern>
|
||||
</encoder>
|
||||
<filter class="ch.qos.logback.classic.filter.ThresholdFilter">
|
||||
<level>INFO</level>
|
||||
</filter>
|
||||
</appender>
|
||||
|
||||
<appender name="PALLETFILE" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<file>logs/pallet.log</file>
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<fileNamePattern>logs/old/pallet.%d{yyyy-MM-dd}.log</fileNamePattern>
|
||||
<maxHistory>3</maxHistory>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>%date %level [%thread] %logger{10} %msg%n</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<logger name="clj-ssh.ssh" level="ERROR">
|
||||
<appender-ref ref="PALLETFILE" />
|
||||
</logger>
|
||||
|
||||
<logger name="pallet" level="DEBUG">
|
||||
<appender-ref ref="PALLETFILE" />
|
||||
</logger>
|
||||
|
||||
<logger name="pallet.ssh" level="ERROR">
|
||||
<appender-ref ref="PALLETFILE" />
|
||||
</logger>
|
||||
|
||||
<logger name="pallet.algo" level="ERROR">
|
||||
<appender-ref ref="PALLETFILE" />
|
||||
</logger>
|
||||
|
||||
<logger name="dda" level="DEBUG">
|
||||
<appender-ref ref="PALLETFILE" />
|
||||
</logger>
|
||||
|
||||
<logger name="meissa" level="DEBUG">
|
||||
<appender-ref ref="PALLETFILE" />
|
||||
</logger>
|
||||
|
||||
<root level="DEBUG">
|
||||
<appender-ref ref="CONSOLE" />
|
||||
</root>
|
||||
|
||||
</configuration>
|
|
@ -1,57 +0,0 @@
|
|||
(ns meissa.pallet.meissa-nextcloud.main
|
||||
(:gen-class)
|
||||
(:require
|
||||
[clojure.string :as str]
|
||||
[clojure.tools.cli :as cli]
|
||||
[dda.pallet.core.main-helper :as mh]
|
||||
[dda.pallet.core.app :as core-app]
|
||||
[meissa.pallet.meissa-nextcloud.app :as app]))
|
||||
|
||||
(def cli-options
|
||||
[["-h" "--help"]
|
||||
["-c" "--configure"]
|
||||
["-t" "--targets example-targets.edn" "edn file containing the targets to install on."
|
||||
:default "localhost-target.edn"]
|
||||
["-v" "--verbose"]])
|
||||
|
||||
(defn usage [options-summary]
|
||||
(str/join
|
||||
\newline
|
||||
["meissa-nextcloud installs & configures a single host kubernetes cluster with nextcloud installed"
|
||||
""
|
||||
"Usage: java -jar meissa-nextcloud-standalone.jar [options] nextcloud.edn"
|
||||
""
|
||||
"Options:"
|
||||
options-summary
|
||||
""
|
||||
"nextcloud.edn"
|
||||
" - follows the edn format."
|
||||
" - has to be a valid nextcloudConventionConfig"
|
||||
""]))
|
||||
|
||||
(defn -main [& args]
|
||||
(let [{:keys [options arguments errors summary help]} (cli/parse-opts args cli-options)
|
||||
verbose (if (contains? options :verbose) 1 0)]
|
||||
(cond
|
||||
help (mh/exit 0 (usage summary))
|
||||
errors (mh/exit 1 (mh/error-msg errors))
|
||||
(not= (count arguments) 1) (mh/exit 1 (usage summary))
|
||||
(:serverspec options) (if (core-app/existing-serverspec
|
||||
app/crate-app
|
||||
{:convention (first arguments)
|
||||
:targets (:targets options)
|
||||
:verbosity verbose})
|
||||
(mh/exit-test-passed)
|
||||
(mh/exit-test-failed))
|
||||
(:configure options) (if (core-app/existing-configure
|
||||
app/crate-app
|
||||
{:convention (first arguments)
|
||||
:targets (:targets options)})
|
||||
(mh/exit-default-success)
|
||||
(mh/exit-default-error))
|
||||
:default (if (core-app/existing-install
|
||||
app/crate-app
|
||||
{:convention (first arguments)
|
||||
:targets (:targets options)})
|
||||
(mh/exit-default-success)
|
||||
(mh/exit-default-error)))))
|
Loading…
Reference in a new issue