Compare commits

...

3 Commits

Author SHA1 Message Date
Viktor Scharf
d2ef444d8b replace antivirus 2026-01-07 15:58:48 +01:00
Viktor Scharf
64a9efffff fix 2026-01-07 15:23:05 +01:00
Viktor Scharf
e7146780fa replace CI images 2026-01-07 14:37:41 +01:00
10 changed files with 55 additions and 59 deletions

View File

@@ -15,16 +15,16 @@ OPEN_SEARCH = "opensearchproject/opensearch:2"
INBUCKET_INBUCKET = "inbucket/inbucket" INBUCKET_INBUCKET = "inbucket/inbucket"
MINIO_MC = "minio/mc:RELEASE.2021-10-07T04-19-58Z" MINIO_MC = "minio/mc:RELEASE.2021-10-07T04-19-58Z"
OC_CI_ALPINE = "owncloudci/alpine:latest" OC_CI_ALPINE = "owncloudci/alpine:latest"
OC_CI_BAZEL_BUILDIFIER = "owncloudci/bazel-buildifier:latest" OC_CI_BAZEL_BUILDIFIER = "scharfvi/bazel-buildifier:latest"
OC_CI_CLAMAVD = "owncloudci/clamavd" OC_CI_CLAMAVD = "scharfvi/clamav:latest"
OC_CI_DRONE_ANSIBLE = "owncloudci/drone-ansible:latest" OC_CI_DRONE_ANSIBLE = "owncloudci/drone-ansible:latest"
OC_CI_GOLANG = "registry.heinlein.group/opencloud/golang-ci:1.25" OC_CI_GOLANG = "quay.io/opencloudeu/golang-ci:1.25"
OC_CI_NODEJS = "owncloudci/nodejs:%s" OC_CI_NODEJS = "scharfvi/nodeci:24"
OC_CI_PHP = "owncloudci/php:%s" OC_CI_NODEJS_ALPINE = "scharfvi/nodeci-alpine:24"
OC_CI_WAIT_FOR = "owncloudci/wait-for:latest" OC_CI_PHP = "scharfvi/php-alpine-ci:%s"
OC_CI_WAIT_FOR = "scharfvi/wait-for:latest"
OC_CS3_API_VALIDATOR = "opencloudeu/cs3api-validator:latest" OC_CS3_API_VALIDATOR = "opencloudeu/cs3api-validator:latest"
OC_LITMUS = "owncloudci/litmus:latest" OC_LITMUS = "owncloudci/litmus:latest"
OC_UBUNTU = "owncloud/ubuntu:20.04"
ONLYOFFICE_DOCUMENT_SERVER = "onlyoffice/documentserver:7.5.1" ONLYOFFICE_DOCUMENT_SERVER = "onlyoffice/documentserver:7.5.1"
PLUGINS_DOCKER_BUILDX = "woodpeckerci/plugin-docker-buildx:latest" PLUGINS_DOCKER_BUILDX = "woodpeckerci/plugin-docker-buildx:latest"
PLUGINS_NOTATION = "registry.heinlein.group/opencloud/notation-wp-plugin:latest" PLUGINS_NOTATION = "registry.heinlein.group/opencloud/notation-wp-plugin:latest"
@@ -37,8 +37,7 @@ REDIS = "redis:6-alpine"
READY_RELEASE_GO = "woodpeckerci/plugin-ready-release-go:latest" READY_RELEASE_GO = "woodpeckerci/plugin-ready-release-go:latest"
OPENLDAP = "bitnamilegacy/openldap:2.6" OPENLDAP = "bitnamilegacy/openldap:2.6"
DEFAULT_PHP_VERSION = "8.2" DEFAULT_PHP_VERSION = "8.4"
DEFAULT_NODEJS_VERSION = "20"
CACHE_S3_SERVER = "https://s3.ci.opencloud.eu" CACHE_S3_SERVER = "https://s3.ci.opencloud.eu"
@@ -611,7 +610,7 @@ def savePipelineNumber(ctx):
def evaluateWorkflowStep(): def evaluateWorkflowStep():
return [{ return [{
"name": "evaluate-previous-run", "name": "evaluate-previous-run",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS_ALPINE,
"commands": [ "commands": [
"node tests/config/woodpecker/evaluate_pipeline.js", "node tests/config/woodpecker/evaluate_pipeline.js",
], ],
@@ -728,7 +727,7 @@ def cacheGoBin():
}, },
{ {
"name": "archive-go-bin", "name": "archive-go-bin",
"image": OC_UBUNTU, "image": OC_CI_NODEJS,
"commands": [ "commands": [
". ./.env", ". ./.env",
"if $BIN_CACHE_FOUND; then exit 0; fi", "if $BIN_CACHE_FOUND; then exit 0; fi",
@@ -766,7 +765,7 @@ def restoreGoBinCache():
}, },
{ {
"name": "extract-go-bin-cache", "name": "extract-go-bin-cache",
"image": OC_UBUNTU, "image": OC_CI_NODEJS,
"commands": [ "commands": [
"tar -xvmf %s -C /" % dirs["gobinTarPath"], "tar -xvmf %s -C /" % dirs["gobinTarPath"],
], ],
@@ -966,7 +965,7 @@ def checkGherkinLint(ctx):
"steps": [ "steps": [
{ {
"name": "lint-feature-files", "name": "lint-feature-files",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS_ALPINE,
"commands": [ "commands": [
"npm install -g @gherlint/gherlint@1.1.0", "npm install -g @gherlint/gherlint@1.1.0",
"make test-gherkin-lint", "make test-gherkin-lint",
@@ -1552,7 +1551,7 @@ def e2eTestPipeline(ctx):
step_e2e = { step_e2e = {
"name": "e2e-tests", "name": "e2e-tests",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS,
"environment": { "environment": {
"OC_BASE_URL": OC_DOMAIN, "OC_BASE_URL": OC_DOMAIN,
"HEADLESS": True, "HEADLESS": True,
@@ -1727,7 +1726,7 @@ def multiServiceE2ePipeline(ctx):
storage_users_services + \ storage_users_services + \
[{ [{
"name": "e2e-tests", "name": "e2e-tests",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS,
"environment": { "environment": {
"OC_BASE_URL": OC_DOMAIN, "OC_BASE_URL": OC_DOMAIN,
"HEADLESS": True, "HEADLESS": True,
@@ -2059,14 +2058,14 @@ def licenseCheck(ctx):
"steps": restoreGoBinCache() + [ "steps": restoreGoBinCache() + [
{ {
"name": "node-check-licenses", "name": "node-check-licenses",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS_ALPINE,
"commands": [ "commands": [
"make ci-node-check-licenses", "make ci-node-check-licenses",
], ],
}, },
{ {
"name": "node-save-licenses", "name": "node-save-licenses",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS_ALPINE,
"commands": [ "commands": [
"make ci-node-save-licenses", "make ci-node-save-licenses",
], ],
@@ -2186,7 +2185,7 @@ def makeNodeGenerate(module):
return [ return [
{ {
"name": "generate nodejs", "name": "generate nodejs",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS,
"environment": { "environment": {
"CHROMEDRIVER_SKIP_DOWNLOAD": True, # install fails on arm and chromedriver is a test only dependency "CHROMEDRIVER_SKIP_DOWNLOAD": True, # install fails on arm and chromedriver is a test only dependency
}, },
@@ -2864,7 +2863,7 @@ def litmus(ctx, storage):
def setupForLitmus(): def setupForLitmus():
return [{ return [{
"name": "setup-for-litmus", "name": "setup-for-litmus",
"image": OC_UBUNTU, "image": OC_CI_NODEJS,
"environment": { "environment": {
"TEST_SERVER_URL": OC_URL, "TEST_SERVER_URL": OC_URL,
}, },
@@ -2879,7 +2878,7 @@ def getWoodpeckerEnvAndCheckScript(ctx):
path_to_check_script = "%s/tests/config/woodpecker/check_web_cache.sh" % dirs["base"] path_to_check_script = "%s/tests/config/woodpecker/check_web_cache.sh" % dirs["base"]
return { return {
"name": "get-woodpecker-env-and-check-script", "name": "get-woodpecker-env-and-check-script",
"image": OC_UBUNTU, "image": OC_CI_NODEJS,
"commands": [ "commands": [
"cp %s check_web_cache.sh" % path_to_check_script, "cp %s check_web_cache.sh" % path_to_check_script,
], ],
@@ -2898,7 +2897,7 @@ def checkForWebCache(name):
def cloneWeb(): def cloneWeb():
return { return {
"name": "clone-web", "name": "clone-web",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS_ALPINE,
"commands": [ "commands": [
". ./.woodpecker.env", ". ./.woodpecker.env",
"if $WEB_CACHE_FOUND; then exit 0; fi", "if $WEB_CACHE_FOUND; then exit 0; fi",
@@ -2915,7 +2914,7 @@ def generateWebPnpmCache(ctx):
cloneWeb(), cloneWeb(),
{ {
"name": "install-pnpm", "name": "install-pnpm",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS,
"commands": [ "commands": [
". ./.woodpecker.env", ". ./.woodpecker.env",
"if $WEB_CACHE_FOUND; then exit 0; fi", "if $WEB_CACHE_FOUND; then exit 0; fi",
@@ -2927,7 +2926,7 @@ def generateWebPnpmCache(ctx):
}, },
{ {
"name": "zip-pnpm", "name": "zip-pnpm",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS,
"commands": [ "commands": [
". ./.woodpecker.env", ". ./.woodpecker.env",
"if $WEB_CACHE_FOUND; then exit 0; fi", "if $WEB_CACHE_FOUND; then exit 0; fi",
@@ -2989,7 +2988,7 @@ def cacheBrowsers(ctx):
browser_cache_steps = [ browser_cache_steps = [
{ {
"name": "install-browsers", "name": "install-browsers",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS,
"environment": { "environment": {
"PLAYWRIGHT_BROWSERS_PATH": ".playwright", "PLAYWRIGHT_BROWSERS_PATH": ".playwright",
}, },
@@ -2997,7 +2996,7 @@ def cacheBrowsers(ctx):
"cd %s" % dirs["web"], "cd %s" % dirs["web"],
". ./.woodpecker.env", ". ./.woodpecker.env",
"if $BROWSER_CACHE_FOUND; then exit 0; fi", "if $BROWSER_CACHE_FOUND; then exit 0; fi",
"pnpm exec playwright install --with-deps", "pnpm exec playwright install",
"pnpm exec playwright install --list", "pnpm exec playwright install --list",
"tar -czf %s .playwright" % dirs["playwrightBrowsersArchive"], "tar -czf %s .playwright" % dirs["playwrightBrowsersArchive"],
], ],
@@ -3032,7 +3031,7 @@ def generateWebCache(ctx):
cloneWeb(), cloneWeb(),
{ {
"name": "zip-web", "name": "zip-web",
"image": OC_UBUNTU, "image": OC_CI_NODEJS,
"commands": [ "commands": [
". ./.woodpecker.env", ". ./.woodpecker.env",
"if $WEB_CACHE_FOUND; then exit 0; fi", "if $WEB_CACHE_FOUND; then exit 0; fi",
@@ -3068,7 +3067,7 @@ def restoreWebCache():
], ],
}, { }, {
"name": "unzip-web-cache", "name": "unzip-web-cache",
"image": OC_UBUNTU, "image": OC_CI_NODEJS,
"commands": [ "commands": [
"tar -xf %s -C ." % dirs["webZip"], "tar -xf %s -C ." % dirs["webZip"],
], ],
@@ -3087,7 +3086,7 @@ def restoreWebPnpmCache(extra_commands = []):
}, { }, {
# we need to install again because the node_modules are not cached # we need to install again because the node_modules are not cached
"name": "unzip-and-install-pnpm", "name": "unzip-and-install-pnpm",
"image": OC_CI_NODEJS % DEFAULT_NODEJS_VERSION, "image": OC_CI_NODEJS,
"commands": extra_commands + [ "commands": extra_commands + [
"cd %s" % dirs["web"], "cd %s" % dirs["web"],
"rm -rf .pnpm-store", "rm -rf .pnpm-store",
@@ -3113,7 +3112,7 @@ def restoreBrowsersCache():
}, },
{ {
"name": "unzip-browsers-cache", "name": "unzip-browsers-cache",
"image": OC_UBUNTU, "image": OC_CI_NODEJS,
"commands": [ "commands": [
"tar -xf /woodpecker/src/github.com/%s/webTestRunner/playwright-browsers.tar.gz -C ." % repo_slug, "tar -xf /woodpecker/src/github.com/%s/webTestRunner/playwright-browsers.tar.gz -C ." % repo_slug,
], ],
@@ -3131,7 +3130,7 @@ def waitForEmailService():
"name": "wait-for-email", "name": "wait-for-email",
"image": OC_CI_WAIT_FOR, "image": OC_CI_WAIT_FOR,
"commands": [ "commands": [
"wait-for -it email:9000 -t 600", "wait-for -host email -port 9000 -timeout 600",
], ],
}] }]
@@ -3146,7 +3145,7 @@ def waitForClamavService():
"name": "wait-for-clamav", "name": "wait-for-clamav",
"image": OC_CI_WAIT_FOR, "image": OC_CI_WAIT_FOR,
"commands": [ "commands": [
"wait-for -it clamav:3310 -t 600", "wait-for -host clamav -port 3310 -timeout 600",
], ],
}] }]
@@ -3189,7 +3188,7 @@ def waitForLdapService():
"name": "wait-for-ldap", "name": "wait-for-ldap",
"image": OC_CI_WAIT_FOR, "image": OC_CI_WAIT_FOR,
"commands": [ "commands": [
"wait-for -it ldap-server:1636 -t 600", "wait-for -host ldap-server -port 1636 -timeout 600",
], ],
}] }]
@@ -3252,7 +3251,7 @@ def tikaService():
"name": "wait-for-tika-service", "name": "wait-for-tika-service",
"image": OC_CI_WAIT_FOR, "image": OC_CI_WAIT_FOR,
"commands": [ "commands": [
"wait-for -it tika:9998 -t 300", "wait-for -host tika -port 9998 -timeout 300",
], ],
}] }]
@@ -3367,13 +3366,18 @@ def k6LoadTests(ctx):
return [pipeline] return [pipeline]
def waitForServices(name, services = []): def waitForServices(name, services = []):
services = ",".join(services) commands = []
for service in services:
host, port = service.split(":", 1)
commands.append(
"wait-for -host %s -port %s -timeout 300" % (host, port),
)
return [{ return [{
"name": "wait-for-%s" % name, "name": "wait-for-%s" % name,
"image": OC_CI_WAIT_FOR, "image": OC_CI_WAIT_FOR,
"commands": [ "commands": commands,
"wait-for -it %s -t 300" % services,
],
}] }]
def openCloudHealthCheck(name, services = []): def openCloudHealthCheck(name, services = []):

View File

@@ -1,8 +1,8 @@
{ {
"name": "opencloud-eu/opencloud", "name": "opencloud-eu/opencloud",
"config" : { "config": {
"platform": { "platform": {
"php": "8.2" "php": "8.3"
}, },
"vendor-dir": "./vendor-php", "vendor-dir": "./vendor-php",
"allow-plugins": { "allow-plugins": {

View File

@@ -437,18 +437,10 @@ Start ClamAV daemon
#### 2. Setup clamAV With Docker #### 2. Setup clamAV With Docker
##### Linux OS user
Run `clamAV` through docker Run `clamAV` through docker
```bash ```bash
docker run -d -p 3310:3310 owncloudci/clamavd docker run -d -p 3310:3310 scharfvi/clamav:latest
```
##### Mac OS user
```bash
docker run -d -p 3310:3310 -v /your/local/filesystem/path/to/clamav/:/var/lib/clamav mkodockx/docker-clamav:alpine
``` ```
### Run OpenCloud ### Run OpenCloud

View File

@@ -1577,7 +1577,7 @@ class FeatureContext extends BehatVariablesContext {
* *
* @return mixed * @return mixed
*/ */
public function getJsonDecodedResponseBodyContent(ResponseInterface $response = null): mixed { public function getJsonDecodedResponseBodyContent(?ResponseInterface $response = null): mixed {
$response = $response ?? $this->response; $response = $response ?? $this->response;
$response->getBody()->rewind(); $response->getBody()->rewind();
return HttpRequestHelper::getJsonDecodedResponseBodyContent($response); return HttpRequestHelper::getJsonDecodedResponseBodyContent($response);

View File

@@ -1025,7 +1025,7 @@ trait Provisioning {
*/ */
public function userHasBeenCreated( public function userHasBeenCreated(
array $userData, array $userData,
string $byUser = null ?string $byUser = null
): void { ): void {
$userId = null; $userId = null;

View File

@@ -450,7 +450,7 @@ trait Sharing {
string $user, string $user,
string $path, string $path,
bool $publicUpload = false, bool $publicUpload = false,
string $sharePassword = null, ?string $sharePassword = null,
$permissions = null, $permissions = null,
?string $linkName = null, ?string $linkName = null,
?string $expireDate = null ?string $expireDate = null
@@ -1207,7 +1207,7 @@ trait Sharing {
*/ */
public function deleteLastShareUsingSharingApi( public function deleteLastShareUsingSharingApi(
string $user, string $user,
string $sharer = null, ?string $sharer = null,
bool $deleteLastPublicLink = false bool $deleteLastPublicLink = false
): ResponseInterface { ): ResponseInterface {
$user = $this->getActualUsername($user); $user = $this->getActualUsername($user);
@@ -2672,7 +2672,7 @@ trait Sharing {
* @return ResponseInterface * @return ResponseInterface
* @throws GuzzleException * @throws GuzzleException
*/ */
public function expireShare(string $shareId = null): ResponseInterface { public function expireShare(?string $shareId = null): ResponseInterface {
$adminUser = $this->getAdminUsername(); $adminUser = $this->getAdminUsername();
if ($shareId === null) { if ($shareId === null) {
$shareId = $this->getLastCreatedUserGroupShareId(); $shareId = $this->getLastCreatedUserGroupShareId();

View File

@@ -1644,7 +1644,7 @@ trait WebDav {
string $user, string $user,
string $source, string $source,
string $destination, string $destination,
string $spaceId = null, ?string $spaceId = null,
?bool $isGivenStep = false ?bool $isGivenStep = false
): ResponseInterface { ): ResponseInterface {
$user = $this->getActualUsername($user); $user = $this->getActualUsername($user);
@@ -4054,7 +4054,7 @@ trait WebDav {
* *
* @return string|null * @return string|null
*/ */
public function getFileIdForPath(string $user, string $path, string $spaceId = null): ?string { public function getFileIdForPath(string $user, string $path, ?string $spaceId = null): ?string {
$user = $this->getActualUsername($user); $user = $this->getActualUsername($user);
try { try {
return WebDavHelper::getFileIdForPath( return WebDavHelper::getFileIdForPath(

View File

@@ -1,6 +1,6 @@
services: services:
acceptance-tests: acceptance-tests:
image: owncloudci/php:8.2 image: scharfvi/php-alpine-ci:8.4
working_dir: /woodpecker/src/github.com/opencloud-eu/opencloud working_dir: /woodpecker/src/github.com/opencloud-eu/opencloud
command: /bin/bash /test/run-tests.sh command: /bin/bash /test/run-tests.sh
environment: environment:

View File

@@ -5,5 +5,5 @@ services:
- clamav - clamav
command: clamav:3310 command: clamav:3310
clamav: clamav:
image: mkodockx/docker-clamav:alpine image: scharfvi/clamav:latest

View File

@@ -1,7 +1,7 @@
{ {
"config": { "config": {
"platform": { "platform": {
"php": "8.2" "php": "8.3"
}, },
"allow-plugins": { "allow-plugins": {
"composer/package-versions-deprecated": true "composer/package-versions-deprecated": true
@@ -20,7 +20,7 @@
"guzzlehttp/guzzle": "^7.7", "guzzlehttp/guzzle": "^7.7",
"phpunit/phpunit": "^9.6", "phpunit/phpunit": "^9.6",
"laminas/laminas-ldap": "^2.15", "laminas/laminas-ldap": "^2.15",
"ankitpokhrel/tus-php": "^2.3", "ankitpokhrel/tus-php": "^2.4",
"swaggest/json-schema": "^0.12.42", "swaggest/json-schema": "^0.12.42",
"splitbrain/php-archive": "^1.3" "splitbrain/php-archive": "^1.3"
} }