Skip to content

Commit 08f98c5

Browse files
run api tests on s3ng
1 parent 7f56ac4 commit 08f98c5

File tree

9 files changed

+118
-17
lines changed

9 files changed

+118
-17
lines changed
Lines changed: 101 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,101 @@
1+
---
2+
depends_on: [ build ]
3+
4+
variables:
5+
- &golang_image 'docker.io/golang:1.24'
6+
- &alpine_image 'owncloudci/alpine:latest'
7+
- &behat_image 'cs3org/behat:latest'
8+
9+
when:
10+
- event: [ push , manual ]
11+
branch: ${CI_REPO_DEFAULT_BRANCH}
12+
- event: [ pull_request ]
13+
14+
matrix:
15+
RUN_PART: [ 1, 2, 3, 4 ]
16+
17+
steps:
18+
fetch-binary:
19+
image: minio/mc:RELEASE.2021-10-07T04-19-58Z
20+
environment:
21+
AWS_ACCESS_KEY_ID:
22+
from_secret: cache_s3_access_key
23+
AWS_SECRET_ACCESS_KEY:
24+
from_secret: cache_s3_secret_key
25+
S3_BUCKET:
26+
from_secret: cache_s3_bucket
27+
S3_ENDPOINT:
28+
from_secret: cache_s3_server
29+
commands:
30+
- mc alias set s3 $S3_ENDPOINT $AWS_ACCESS_KEY_ID $AWS_SECRET_ACCESS_KEY
31+
- mc cp -a s3/$S3_BUCKET/opencloud-eu/reva/$CI_COMMIT_SHA-$CI_PIPELINE_NUMBER-revad $CI_WORKSPACE/cmd/revad/revad
32+
revad-services:
33+
image: *golang_image
34+
detach: true
35+
commands:
36+
- cd tests/oc-integration-tests/ci/
37+
- ../../../cmd/revad/revad -c frontend.toml &
38+
- ../../../cmd/revad/revad -c gateway.toml &
39+
- ../../../cmd/revad/revad -c shares.toml &
40+
- ../../../cmd/revad/revad -c storage-shares.toml &
41+
- ../../../cmd/revad/revad -c machine-auth.toml &
42+
- ../../../cmd/revad/revad -c storage-users-decomposeds3.toml &
43+
- ../../../cmd/revad/revad -c storage-publiclink.toml &
44+
- ../../../cmd/revad/revad -c permissions-demo-ci.toml &
45+
- ../../../cmd/revad/revad -c ldap-users.toml
46+
wait_for_server:
47+
image: ghcr.io/dvjn/woodpecker-is-it-up-yet-plugin
48+
settings:
49+
host: revad-services
50+
port: 19000
51+
52+
clone_api_tests:
53+
image: *alpine_image
54+
commands:
55+
- . ./.woodpecker.env
56+
- git clone -b $APITESTS_BRANCH --single-branch --no-tags $APITESTS_REPO_GIT_URL
57+
- cd opencloud
58+
- git checkout $APITESTS_COMMITID
59+
60+
api-tests-opencloud:
61+
image: *behat_image
62+
commands:
63+
- cd opencloud
64+
- make test-acceptance-api
65+
environment:
66+
TEST_SERVER_URL: "http://revad-services:20080"
67+
OC_REVA_DATA_ROOT: "/woodpecker/src/reva/data"
68+
DELETE_USER_DATA_CMD: "rm -rf /woodpecker/src/reva/data/spaces/* /woodpecker/src/reva/data/blobs/* /woodpecker/src/reva/data/indexes/by-type/*"
69+
STORAGE_DRIVER: "POSIX"
70+
TEST_WITH_LDAP: "true"
71+
REVA_LDAP_HOSTNAME: "ldap"
72+
TEST_REVA: True
73+
SEND_SCENARIO_LINE_REFERENCES: True
74+
BEHAT_FILTER_TAGS: "~@skip&&~@skipOnReva&&~@env-config"
75+
DIVIDE_INTO_NUM_PARTS: "4" # Adjust this based on total parts
76+
RUN_PART: "${RUN_PART}"
77+
EXPECTED_FAILURES_FILE: "/woodpecker/src/github.com/opencloud-eu/reva/tests/acceptance/expected-failures-on-DECOMPOSEDS3-storage.md"
78+
ACCEPTANCE_TEST_TYPE: "core-api"
79+
80+
services:
81+
ldap:
82+
image: 'osixia/openldap:1.3.0'
83+
environment:
84+
LDAP_DOMAIN: "example.org"
85+
LDAP_ORGANISATION: "example"
86+
LDAP_ADMIN_PASSWORD: "admin"
87+
LDAP_TLS_VERIFY_CLIENT: "never"
88+
HOSTNAME: "ldap"
89+
ceph:
90+
image: 'ceph/daemon'
91+
environment:
92+
CEPH_DAEMON: "demo"
93+
NETWORK_AUTO_DETECT: "4"
94+
MON_IP: "0.0.0.0"
95+
CEPH_PUBLIC_NETWORK: "0.0.0.0/0"
96+
RGW_CIVETWEB_PORT: "4000"
97+
RGW_NAME: "ceph"
98+
CEPH_DEMO_UID: "test-user"
99+
CEPH_DEMO_ACCESS_KEY: "test"
100+
CEPH_DEMO_SECRET_KEY: "test"
101+
CEPH_DEMO_BUCKET: "test"

tests/oc-integration-tests/ci/gateway-virtual.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ datagateway = "http://localhost:19001/data"
3737
transfer_shared_secret = "replace-me-with-a-transfer-secret" # for direct uploads
3838
transfer_expires = 6 # give it a moment
3939
#disable_home_creation_on_login = true
40-
link_grants_file = "/go/src/tmp/reva/link_grants_file.json"
40+
link_grants_file = "/woodpecker/src/reva/link_grants_file.json"
4141

4242
[grpc.services.authregistry]
4343
driver = "static"

tests/oc-integration-tests/ci/gateway.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ datagateway = "http://localhost:19001/data"
3939
transfer_shared_secret = "replace-me-with-a-transfer-secret" # for direct uploads
4040
transfer_expires = 6 # give it a moment
4141
#disable_home_creation_on_login = true
42-
link_grants_file = "/go/src/tmp/reva/link_grants_file.json"
42+
link_grants_file = "/woodpecker/src/reva/link_grants_file.json"
4343

4444
[grpc.services.authregistry]
4545
driver = "static"

tests/oc-integration-tests/ci/shares.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,5 @@ auth_manager = "publicshares"
1717
gateway_addr = "localhost:19000"
1818

1919
[grpc.services.publicshareprovider.drivers.json]
20-
file = "/go/src/tmp/reva/publicshares.json"
20+
file = "/woodpecker/src/reva/publicshares.json"
2121
gateway_addr = "localhost:19000"

tests/oc-integration-tests/ci/storage-users-0-9.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ expose_data_server = true
2323
data_server_url = "http://revad-services:11001/data"
2424

2525
[grpc.services.storageprovider.drivers.decomposed]
26-
root = "/go/src/tmp/reva/data-0-9"
26+
root = "/woodpecker/src/reva/data-0-9"
2727
treetime_accounting = true
2828
treesize_accounting = true
2929
permissionssvc = "localhost:10000"
@@ -34,10 +34,10 @@ address = "0.0.0.0:11001"
3434

3535
[http.services.dataprovider]
3636
driver = "decomposed"
37-
temp_folder = "/var/tmp/reva/tmp"
37+
temp_folder = "/woodpecker/src/reva/tmp"
3838

3939
[http.services.dataprovider.drivers.decomposed]
40-
root = "/go/src/tmp/reva/data-0-9"
40+
root = "/woodpecker/src/reva/data-0-9"
4141
treetime_accounting = true
4242
treesize_accounting = true
4343
permissionssvc = "localhost:10000"

tests/oc-integration-tests/ci/storage-users-a-f.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ expose_data_server = true
2323
data_server_url = "http://revad-services:11011/data"
2424

2525
[grpc.services.storageprovider.drivers.decomposed]
26-
root = "/go/src/tmp/reva/data-a-f"
26+
root = "/woodpecker/src/reva/data-a-f"
2727
treetime_accounting = true
2828
treesize_accounting = true
2929
permissionssvc = "localhost:10000"
@@ -37,7 +37,7 @@ driver = "decomposed"
3737
temp_folder = "/var/tmp/reva/tmp"
3838

3939
[http.services.dataprovider.drivers.decomposed]
40-
root = "/go/src/tmp/reva/data-a-f"
40+
root = "/woodpecker/src/reva/data-a-f"
4141
treetime_accounting = true
4242
treesize_accounting = true
4343
permissionssvc = "localhost:10000"

tests/oc-integration-tests/ci/storage-users-decomposed.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ gateway_addr = "0.0.0.0:19000"
2121
mount_id = "1284d238-aa92-42ce-bdc4-0b0000009157"
2222

2323
[grpc.services.storageprovider.drivers.decomposed]
24-
root = "/go/src/tmp/reva/data"
24+
root = "/woodpecker/src/reva/data"
2525
treetime_accounting = true
2626
treesize_accounting = true
2727
permissionssvc = "localhost:10000"
@@ -35,10 +35,10 @@ address = "0.0.0.0:11001"
3535

3636
[http.services.dataprovider]
3737
driver = "decomposed"
38-
temp_folder = "/go/src/tmp/reva/tmp"
38+
temp_folder = "/woodpecker/src/reva/tmp"
3939

4040
[http.services.dataprovider.drivers.decomposed]
41-
root = "/go/src/tmp/reva/data"
41+
root = "/woodpecker/src/reva/data"
4242
treetime_accounting = true
4343
treesize_accounting = true
4444
permissionssvc = "localhost:10000"

tests/oc-integration-tests/ci/storage-users-decomposeds3.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@ data_server_url = "http://revad-services:11001/data"
1919
mount_id = "1284d238-aa92-42ce-bdc4-0b0000009157"
2020

2121
[grpc.services.storageprovider.drivers.decomposeds3]
22-
root = "/go/src/tmp/reva/data"
22+
root = "/woodpecker/src/reva/data"
2323
treetime_accounting = true
2424
treesize_accounting = true
2525
permissionssvc = "localhost:10000"
@@ -36,10 +36,10 @@ address = "0.0.0.0:11001"
3636

3737
[http.services.dataprovider]
3838
driver = "decomposeds3"
39-
temp_folder = "/go/src/tmp/reva/tmp"
39+
temp_folder = "/woodpecker/src/reva/tmp"
4040

4141
[http.services.dataprovider.drivers.decomposeds3]
42-
root = "/go/src/tmp/reva/data"
42+
root = "/woodpecker/src/reva/data"
4343
treetime_accounting = true
4444
treesize_accounting = true
4545
permissionssvc = "localhost:10000"

tests/oc-integration-tests/ci/storage-users-posix.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ gateway_addr = "0.0.0.0:19000"
2020
mount_id = "1284d238-aa92-42ce-bdc4-0b0000009157"
2121

2222
[grpc.services.storageprovider.drivers.posix]
23-
root = "/go/src/tmp/reva/data"
23+
root = "/woodpecker/src/reva/data"
2424
permissionssvc = "localhost:10000"
2525
treetime_accounting = true
2626
treesize_accounting = true
@@ -42,10 +42,10 @@ address = "0.0.0.0:11001"
4242

4343
[http.services.dataprovider]
4444
driver = "posix"
45-
temp_folder = "/go/src/tmp/reva/tmp"
45+
temp_folder = "/woodpecker/src/reva/tmp"
4646

4747
[http.services.dataprovider.drivers.posix]
48-
root = "/go/src/tmp/reva/data"
48+
root = "/woodpecker/src/reva/data"
4949
permissionssvc = "localhost:10000"
5050
treetime_accounting = true
5151
treesize_accounting = true

0 commit comments

Comments
 (0)