Skip to content

Commit c2a0f76

Browse files
committed
Merge branch 'master' into release-2.7.2
security updates
2 parents 531115b + cfbd9dd commit c2a0f76

File tree

5 files changed

+49
-127
lines changed

5 files changed

+49
-127
lines changed

.drone.star

Lines changed: 26 additions & 107 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
BANST_AWS_CLI = "banst/awscli"
2-
DRONE_CLI = "drone/cli:alpine"
32
INBUCKET_INBUCKET = "inbucket/inbucket"
43
MINIO_MC = "minio/mc:RELEASE.2020-12-18T10-53-53Z"
54
OC_CI_ALPINE = "owncloudci/alpine:latest"
65
OC_CI_BAZEL_BUILDIFIER = "owncloudci/bazel-buildifier"
76
OC_CI_CEPH = "owncloudci/ceph:tag-build-master-jewel-ubuntu-16.04"
87
OC_CI_CORE = "owncloudci/core"
9-
OC_CI_DRONE_CANCEL_PREVIOUS_BUILDS = "owncloudci/drone-cancel-previous-builds"
108
OC_CI_DRONE_SKIP_PIPELINE = "owncloudci/drone-skip-pipeline"
119
OC_CI_NODEJS = "owncloudci/nodejs:%s"
1210
OC_CI_ORACLE_XE = "owncloudci/oracle-xe:latest"
@@ -23,11 +21,26 @@ PLUGINS_SLACK = "plugins/slack:1"
2321
SELENIUM_STANDALONE_CHROME_DEBUG = "selenium/standalone-chrome-debug:3.141.59-oxygen"
2422
SELENIUM_STANDALONE_FIREFOX_DEBUG = "selenium/standalone-firefox-debug:3.8.1"
2523
SONARSOURCE_SONAR_SCANNER_CLI = "sonarsource/sonar-scanner-cli"
26-
THEGEEKLAB_DRONE_GITHUB_COMMENT = "thegeeklab/drone-github-comment:1"
2724

2825
DEFAULT_PHP_VERSION = "7.4"
2926
DEFAULT_NODEJS_VERSION = "14"
3027

28+
# minio mc environment variables
29+
MINIO_MC_ENV = {
30+
"CACHE_BUCKET": {
31+
"from_secret": "cache_s3_bucket",
32+
},
33+
"MC_HOST": {
34+
"from_secret": "cache_s3_server",
35+
},
36+
"AWS_ACCESS_KEY_ID": {
37+
"from_secret": "cache_s3_access_key",
38+
},
39+
"AWS_SECRET_ACCESS_KEY": {
40+
"from_secret": "cache_s3_secret_key",
41+
},
42+
}
43+
3144
dir = {
3245
"base": "/var/www/owncloud",
3346
"federated": "/var/www/owncloud/federated",
@@ -40,7 +53,7 @@ dir = {
4053
config = {
4154
"rocketchat": {
4255
"channel": "builds",
43-
"from_secret": "private_rocketchat",
56+
"from_secret": "rocketchat_chat_webhook",
4457
},
4558
"branches": [
4659
"master",
@@ -207,7 +220,7 @@ def main(ctx):
207220
return before + coverageTests + afterCoverageTests + nonCoverageTests + stages + after
208221

209222
def beforePipelines(ctx):
210-
return validateDailyTarballBuild() + codestyle(ctx) + jscodestyle(ctx) + cancelPreviousBuilds() + phpstan(ctx) + phan(ctx) + phplint(ctx) + checkStarlark()
223+
return validateDailyTarballBuild() + codestyle(ctx) + jscodestyle(ctx) + phpstan(ctx) + phan(ctx) + phplint(ctx) + checkStarlark()
211224

212225
def coveragePipelines(ctx):
213226
# All unit test pipelines that have coverage or other test analysis reported
@@ -361,31 +374,6 @@ def jscodestyle(ctx):
361374

362375
return pipelines
363376

364-
def cancelPreviousBuilds():
365-
return [{
366-
"kind": "pipeline",
367-
"type": "docker",
368-
"name": "cancel-previous-builds",
369-
"clone": {
370-
"disable": True,
371-
},
372-
"steps": [{
373-
"name": "cancel-previous-builds",
374-
"image": OC_CI_DRONE_CANCEL_PREVIOUS_BUILDS,
375-
"settings": {
376-
"DRONE_TOKEN": {
377-
"from_secret": "drone_token",
378-
},
379-
},
380-
}],
381-
"depends_on": [],
382-
"trigger": {
383-
"ref": [
384-
"refs/pull/**",
385-
],
386-
},
387-
}]
388-
389377
def phpstan(ctx):
390378
pipelines = []
391379

@@ -709,7 +697,7 @@ def javascript(ctx, withCoverage):
709697
"image": PLUGINS_S3,
710698
"settings": {
711699
"endpoint": {
712-
"from_secret": "cache_s3_endpoint",
700+
"from_secret": "cache_s3_server",
713701
},
714702
"bucket": "cache",
715703
"source": "./coverage/lcov.info",
@@ -937,7 +925,7 @@ def phpTests(ctx, testType, withCoverage):
937925
"image": PLUGINS_S3,
938926
"settings": {
939927
"endpoint": {
940-
"from_secret": "cache_s3_endpoint",
928+
"from_secret": "cache_s3_server",
941929
},
942930
"bucket": "cache",
943931
"source": "tests/output/clover-%s.xml" % (name),
@@ -1008,7 +996,6 @@ def acceptance(ctx):
1008996
"skip": False,
1009997
"debugSuites": [],
1010998
"skipExceptParts": [],
1011-
"earlyFail": True,
1012999
"enableApp": True,
10131000
"selUserNeeded": False,
10141001
}
@@ -1046,14 +1033,6 @@ def acceptance(ctx):
10461033
if params["skip"]:
10471034
continue
10481035

1049-
# switch off earlyFail if the PR title contains full-ci
1050-
if ("full-ci" in ctx.build.title.lower()):
1051-
params["earlyFail"] = False
1052-
1053-
# switch off earlyFail when running cron builds (for example, nightly CI)
1054-
if (ctx.build.event == "cron"):
1055-
params["earlyFail"] = False
1056-
10571036
if "externalScality" in params and len(params["externalScality"]) != 0:
10581037
# We want to use an external scality server for this pipeline.
10591038
# That uses some "standard" extraSetup and extraTeardown.
@@ -1265,7 +1244,7 @@ def acceptance(ctx):
12651244
"path": "%s/downloads" % dir["server"],
12661245
}],
12671246
}),
1268-
] + testConfig["extraTeardown"] + githubComment(params["earlyFail"]) + stopBuild(ctx, params["earlyFail"]),
1247+
] + testConfig["extraTeardown"],
12691248
"services": databaseService(testConfig["database"]) +
12701249
browserService(testConfig["browser"]) +
12711250
emailService(testConfig["emailNeeded"]) +
@@ -1350,13 +1329,10 @@ def sonarAnalysis(ctx, phpVersion = DEFAULT_PHP_VERSION):
13501329
{
13511330
"name": "sync-from-cache",
13521331
"image": MINIO_MC,
1353-
"environment": {
1354-
"MC_HOST_cache": {
1355-
"from_secret": "cache_s3_connection_url",
1356-
},
1357-
},
1332+
"environment": MINIO_MC_ENV,
13581333
"commands": [
13591334
"mkdir -p results",
1335+
"mc alias set cache $MC_HOST $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY",
13601336
"mc mirror cache/cache/%s/%s results/" % (ctx.repo.slug, ctx.build.commit + "-${DRONE_BUILD_NUMBER}"),
13611337
],
13621338
},
@@ -1381,12 +1357,9 @@ def sonarAnalysis(ctx, phpVersion = DEFAULT_PHP_VERSION):
13811357
{
13821358
"name": "purge-cache",
13831359
"image": MINIO_MC,
1384-
"environment": {
1385-
"MC_HOST_cache": {
1386-
"from_secret": "cache_s3_connection_url",
1387-
},
1388-
},
1360+
"environment": MINIO_MC_ENV,
13891361
"commands": [
1362+
"mc alias set cache $MC_HOST $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY",
13901363
"mc rm --recursive --force cache/cache/%s/%s" % (ctx.repo.slug, ctx.build.commit + "-${DRONE_BUILD_NUMBER}"),
13911364
],
13921365
},
@@ -1718,7 +1691,7 @@ def cacheRestore():
17181691
"from_secret": "cache_s3_access_key",
17191692
},
17201693
"endpoint": {
1721-
"from_secret": "cache_s3_endpoint",
1694+
"from_secret": "cache_s3_server",
17221695
},
17231696
"restore": True,
17241697
"secret_key": {
@@ -2098,60 +2071,6 @@ def buildTestConfig(params):
20982071
configs.append(config)
20992072
return configs
21002073

2101-
def stopBuild(ctx, earlyFail):
2102-
if (earlyFail):
2103-
return [{
2104-
"name": "stop-build",
2105-
"image": DRONE_CLI,
2106-
"environment": {
2107-
"DRONE_SERVER": "https://drone.owncloud.com",
2108-
"DRONE_TOKEN": {
2109-
"from_secret": "drone_token",
2110-
},
2111-
},
2112-
"commands": [
2113-
"drone build stop owncloud/%s ${DRONE_BUILD_NUMBER}" % ctx.repo.name,
2114-
],
2115-
"when": {
2116-
"status": [
2117-
"failure",
2118-
],
2119-
"event": [
2120-
"pull_request",
2121-
],
2122-
},
2123-
}]
2124-
2125-
else:
2126-
return []
2127-
2128-
def githubComment(earlyFail):
2129-
if (earlyFail):
2130-
return [{
2131-
"name": "github-comment",
2132-
"image": THEGEEKLAB_DRONE_GITHUB_COMMENT,
2133-
"pull": "if-not-exists",
2134-
"settings": {
2135-
"message": ":boom: Acceptance tests pipeline <strong>${DRONE_STAGE_NAME}</strong> failed. The build has been cancelled.\\n\\n${DRONE_BUILD_LINK}/${DRONE_JOB_NUMBER}${DRONE_STAGE_NUMBER}",
2136-
"key": "pr-${DRONE_PULL_REQUEST}",
2137-
"update": "true",
2138-
"api_key": {
2139-
"from_secret": "github_token",
2140-
},
2141-
},
2142-
"when": {
2143-
"status": [
2144-
"failure",
2145-
],
2146-
"event": [
2147-
"pull_request",
2148-
],
2149-
},
2150-
}]
2151-
2152-
else:
2153-
return []
2154-
21552074
def checkStarlark():
21562075
return [{
21572076
"kind": "pipeline",

l10n/pl_PL.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ OC.L10N.register(
77
"Load more activities" : "Załaduj więcej aktywności",
88
", " : ", ",
99
"{parameterList} and {lastParameter}" : "{parameterList} i {lastParameter}",
10+
"_{parameterList} and {linkStart}%n more{linkEnd}_::_{parameterList} and {linkStart}%n more{linkEnd}_" : ["{parameterList} i {linkStart}%n więcej{linkEnd}","{parameterList} i {linkStart}%n więcej{linkEnd}","{parameterList} i {linkStart}%n więcej{linkEnd}","{parameterList} i {linkStart}%n więcej{linkEnd}"],
1011
"in {directory}" : "w {directory}",
1112
"This stream will show events like additions, changes & shares" : "Ten strumień pokaże informacje o dodatkach, zmianachi udostępnieniach",
1213
"There are no events for this filter" : "Nie ma zdarzeń dla tych filtrów",
@@ -26,8 +27,10 @@ OC.L10N.register(
2627
"Hello %s," : "Witaj %s,",
2728
"You are receiving this email because the following things happened at %s" : "Otrzymujesz tę wiadomość, ponieważ w chmurze %s miały miejsce następujące aktywności:",
2829
"* %1$s - %2$s" : "* %1$s - %2$s",
30+
"_* and %n more _::_* and %n more _" : ["* i %n więcej ","* i %n więcej ","* i %n więcej ","* i %n więcej "],
2931
"You are receiving this email because the following things happened at <a href=\"%s\">%s</a>" : "Otrzymałeś tą wiadomość ponieważ zaszły następujące zdarzenia na <a href=\"%s\">%s</a>",
3032
"%1$s - %2$s" : "%1$s - %2$s",
33+
"_and %n more _::_and %n more _" : ["i %n więcej","i %n więcej","i %n więcej","i %n więcej"],
3134
"Activity" : "Aktywność",
3235
"List your own file actions in the stream" : "Wyświetl Twoje czynności w strumieniu",
3336
"Notify about your own actions via email" : "Powiadamiaj mnie o moich aktywnościach przez email",

l10n/pl_PL.json

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
"Load more activities" : "Załaduj więcej aktywności",
66
", " : ", ",
77
"{parameterList} and {lastParameter}" : "{parameterList} i {lastParameter}",
8+
"_{parameterList} and {linkStart}%n more{linkEnd}_::_{parameterList} and {linkStart}%n more{linkEnd}_" : ["{parameterList} i {linkStart}%n więcej{linkEnd}","{parameterList} i {linkStart}%n więcej{linkEnd}","{parameterList} i {linkStart}%n więcej{linkEnd}","{parameterList} i {linkStart}%n więcej{linkEnd}"],
89
"in {directory}" : "w {directory}",
910
"This stream will show events like additions, changes & shares" : "Ten strumień pokaże informacje o dodatkach, zmianachi udostępnieniach",
1011
"There are no events for this filter" : "Nie ma zdarzeń dla tych filtrów",
@@ -24,8 +25,10 @@
2425
"Hello %s," : "Witaj %s,",
2526
"You are receiving this email because the following things happened at %s" : "Otrzymujesz tę wiadomość, ponieważ w chmurze %s miały miejsce następujące aktywności:",
2627
"* %1$s - %2$s" : "* %1$s - %2$s",
28+
"_* and %n more _::_* and %n more _" : ["* i %n więcej ","* i %n więcej ","* i %n więcej ","* i %n więcej "],
2729
"You are receiving this email because the following things happened at <a href=\"%s\">%s</a>" : "Otrzymałeś tą wiadomość ponieważ zaszły następujące zdarzenia na <a href=\"%s\">%s</a>",
2830
"%1$s - %2$s" : "%1$s - %2$s",
31+
"_and %n more _::_and %n more _" : ["i %n więcej","i %n więcej","i %n więcej","i %n więcej"],
2932
"Activity" : "Aktywność",
3033
"List your own file actions in the stream" : "Wyświetl Twoje czynności w strumieniu",
3134
"Notify about your own actions via email" : "Powiadamiaj mnie o moich aktywnościach przez email",

package.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,5 +19,10 @@
1919
"karma-jasmine-sinon": "^1.0.4",
2020
"karma-phantomjs-launcher": "*"
2121
},
22+
"resolutions": {
23+
"minimist": "0.2.4",
24+
"json-schema": "0.4.0",
25+
"qs": "6.7.3"
26+
},
2227
"engine": "node >= 0.8"
2328
}

yarn.lock

Lines changed: 12 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -672,9 +672,10 @@ json-schema-traverse@^0.4.1:
672672
resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz#69f6a87d9513ab8bb8fe63bdb0979c448e684660"
673673
integrity sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==
674674

675-
json-schema@0.2.3:
676-
version "0.2.3"
677-
resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.2.3.tgz#b480c892e59a2f05954ce727bd3f2a4e882f9e13"
675+
json-schema@0.2.3, json-schema@0.4.0:
676+
version "0.4.0"
677+
resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.4.0.tgz#f7de4cf6efab838ebaeb3236474cbba5a1930ab5"
678+
integrity sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA==
678679

679680
json-stringify-safe@~5.0.1:
680681
version "5.0.1"
@@ -840,14 +841,10 @@ minimatch@^3.0.4:
840841
dependencies:
841842
brace-expansion "^1.1.7"
842843

843-
minimist@0.0.8:
844-
version "0.0.8"
845-
resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.0.8.tgz#857fcabfc3397d2625b8228262e86aa7a011b05d"
846-
847-
minimist@^1.2.5:
848-
version "1.2.5"
849-
resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.5.tgz#67d66014b66a6a8aaa0c083c5fd58df4e4e97602"
850-
integrity sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==
844+
minimist@0.0.8, minimist@0.2.4, minimist@^1.2.5:
845+
version "0.2.4"
846+
resolved "https://registry.yarnpkg.com/minimist/-/minimist-0.2.4.tgz#0085d5501e29033748a2f2a4da0180142697a475"
847+
integrity sha512-Pkrrm8NjyQ8yVt8Am9M+yUt74zE3iokhzbG1bFVNjLB92vwM71hf40RkEsryg98BujhVOncKm/C1xROxZ030LQ==
851848

852849
mkdirp@0.5.1:
853850
version "0.5.1"
@@ -991,15 +988,10 @@ qjobs@^1.2.0:
991988
resolved "https://registry.yarnpkg.com/qjobs/-/qjobs-1.2.0.tgz#c45e9c61800bd087ef88d7e256423bdd49e5d071"
992989
integrity sha512-8YOJEHtxpySA3fFDyCRxA+UUV+fA+rTWnuWvylOK/NCjhY+b4ocCtmu8TtsWb+mYeU+GCHf/S66KZF/AsteKHg==
993990

994-
qs@6.7.0:
995-
version "6.7.0"
996-
resolved "https://registry.yarnpkg.com/qs/-/qs-6.7.0.tgz#41dc1a015e3d581f1621776be31afb2876a9b1bc"
997-
integrity sha512-VCdBRNFTX1fyE7Nb6FYoURo/SPe62QCaAyzJvUjwRaIsc+NePBEniHlvxFmmX56+HZphIGtV0XeCirBtpDrTyQ==
998-
999-
qs@~6.5.2:
1000-
version "6.5.3"
1001-
resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.3.tgz#3aeeffc91967ef6e35c0e488ef46fb296ab76aad"
1002-
integrity sha512-qxXIEh4pCGfHICj1mAJQ2/2XVZkjCDTcEgfoSQxc/fYivUZxTkk7L3bDBJSoNrEzXI17oUO5Dp07ktqE5KzczA==
991+
qs@6.7.0, qs@6.7.3, qs@~6.5.2:
992+
version "6.7.3"
993+
resolved "https://registry.yarnpkg.com/qs/-/qs-6.7.3.tgz#67634d715101aa950601f58dbef353b7e1696b95"
994+
integrity sha512-WBoQWf5L/UOLqUj8Mvr4Om7J+ZTCqPbYPHyeLNRS9t9Q3M3/o/9ctpWnlo8yyETPclx7FhH5LidjKKJa9kdSRQ==
1003995

1004996
range-parser@^1.2.1:
1005997
version "1.2.1"

0 commit comments

Comments
 (0)