diff --git a/.drone.star b/.drone.star index dfac3544ebe..c932aeb031f 100644 --- a/.drone.star +++ b/.drone.star @@ -184,7 +184,7 @@ config = { ], "skip": False, "withRemotePhp": [False], - "k8s": False, + "k8s": True, }, "sharingNgAdditionalShareRole": { "suites": [ @@ -1091,7 +1091,7 @@ def localApiTestPipeline(ctx): params[item] = matrix[item] if item in matrix else defaults[item] for storage in params["storages"]: for run_with_remote_php in params["withRemotePhp"]: - run_on_k8s = params["k8s"] and ctx.build.event == "cron" + run_on_k8s = params["k8s"] #and ctx.build.event == "cron" ocis_url = OCIS_URL if run_on_k8s: ocis_url = "https://%s" % OCIS_SERVER_NAME @@ -1108,7 +1108,7 @@ def localApiTestPipeline(ctx): ([] if run_on_k8s else restoreBuildArtifactCache(ctx, "ocis-binary-amd64", "ocis/bin")) + (tikaService() if params["tikaNeeded"] and not run_on_k8s else tikaServiceK8s() if params["tikaNeeded"] and run_on_k8s else []) + (waitForServices("online-offices", ["collabora:9980", "onlyoffice:443", "fakeoffice:8080"]) if params["collaborationServiceNeeded"] else []) + - (waitK3sCluster() + (clamavServiceK8s() if params["antivirusNeeded"] and run_on_k8s else []) + (emailServiceK8s() if params["emailNeeded"] and run_on_k8s else []) + deployOcis() + waitForOcis(ocis_url = ocis_url) + ociswrapper() + waitForOciswrapper() if run_on_k8s else ocisServer(storage, extra_server_environment = params["extraServerEnvironment"], with_wrapper = True, tika_enabled = params["tikaNeeded"], volumes = ([stepVolumeOcisStorage]))) + + (waitK3sCluster() + (clamavServiceK8s() if params["antivirusNeeded"] and run_on_k8s else []) + (emailServiceK8s() if params["emailNeeded"] and run_on_k8s else []) + deployOcis() + waitForOcis(ocis_url = ocis_url, timeout = 600) + ociswrapper() + waitForOciswrapper() if run_on_k8s else ocisServer(storage, extra_server_environment = params["extraServerEnvironment"], with_wrapper = True, tika_enabled = params["tikaNeeded"], volumes = ([stepVolumeOcisStorage]))) + (waitForClamavService() if params["antivirusNeeded"] and not run_on_k8s else exposeAntivirusServiceK8s() if params["antivirusNeeded"] and run_on_k8s else []) + (waitForEmailService() if params["emailNeeded"] and not run_on_k8s else exposeEmailServiceK8s() if params["emailNeeded"] and run_on_k8s else []) + (ocisServer(storage, deploy_type = "federation", extra_server_environment = params["extraServerEnvironment"]) if params["federationServer"] else []) + @@ -1393,7 +1393,7 @@ def coreApiTestPipeline(ctx): for run_with_remote_php in params["withRemotePhp"]: filter_tags = "~@skipOnGraph&&~@skipOnOcis-%s-Storage" % ("OC" if storage == "owncloud" else "OCIS") expected_failures_file = "%s/expected-failures-API-on-%s-storage.md" % (test_dir, storage.upper()) - run_on_k8s = params["k8s"] and ctx.build.event == "cron" + run_on_k8s = params["k8s"] #and ctx.build.event == "cron" ocis_url = OCIS_URL if run_on_k8s: ocis_url = "https://%s" % OCIS_SERVER_NAME @@ -3608,13 +3608,13 @@ def k6LoadTests(ctx): }, }] -def waitForOcis(name = "ocis", ocis_url = OCIS_URL, depends_on = []): +def waitForOcis(name = "ocis", ocis_url = OCIS_URL, depends_on = [], timeout = 300): return [{ "name": "wait-for-%s" % name, "image": OC_CI_ALPINE, "commands": [ # wait for ocis-server to be ready (5 minutes) - "timeout 300 bash -c 'while [ $(curl -sk -uadmin:admin " + + "timeout %s bash -c 'while [ $(curl -sk -uadmin:admin " % timeout + "%s/graph/v1.0/users/admin " % ocis_url + "-w %{http_code} -o /dev/null) != 200 ]; do sleep 1; done'", ], @@ -3826,6 +3826,7 @@ def deployOcis(): "sed -i '/- name: IDM_ADMIN_PASSWORD/a\\\\\\n value: \"admin\"' ./charts/ocis/templates/idm/deployment.yaml", "sed -i '/- name: PROXY_HTTP_ADDR/i\\\\ - name: PROXY_ENABLE_BASIC_AUTH\\\n value: \"true\"' ./charts/ocis/templates/proxy/deployment.yaml", "export KUBECONFIG=%s/kubeconfig-$${DRONE_BUILD_NUMBER}.yaml" % dirs["base"], + "sed -i 's/--timeout 5m0s/--timeout 10m0s/' Makefile", "make helm-install-atomic", ], "volumes": [