diff --git a/.github/workflows/e2e_tests.yml b/.github/workflows/e2e_tests.yml index 64dfdd6010..52ef001d65 100644 --- a/.github/workflows/e2e_tests.yml +++ b/.github/workflows/e2e_tests.yml @@ -12,35 +12,28 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 - with: - repository: datalens-tech/datalens - path: datalens - - uses: actions/checkout@v4 - with: - path: datalens-ui - uses: actions/setup-node@v3 with: node-version: 18 cache: 'npm' - cache-dependency-path: ./datalens-ui/package-lock.json + cache-dependency-path: ./package-lock.json - name: Run Docker Compose and Install dependencies for Datalens-UI - working-directory: ./datalens - run: docker compose -f ./docker-compose.yml -f ../datalens-ui/tests/docker-compose.override.yml up -d & cd ../datalens-ui && npm ci && npm run test:install:chromium & wait + working-directory: ./tests + run: docker compose -f ./docker-compose.e2e.yml up -d & cd .. && npm ci && npm run test:install:chromium & wait - name: Run Test - working-directory: ./datalens-ui run: E2E_DOMAIN="http://localhost:8080" NO_AUTH=true npm run test:e2e:opensource - name: Run Docker Shutdown - working-directory: ./datalens - run: docker compose down + working-directory: ./tests + run: docker compose -f ./docker-compose.e2e.yml down - uses: actions/upload-artifact@v3 if: always() with: name: playwright-report - path: ./datalens-ui/tests/artifacts/ + path: ./tests/artifacts/ retention-days: 30 publish_report: diff --git a/.gitignore b/.gitignore index 863603de17..495894b50f 100644 --- a/.gitignore +++ b/.gitignore @@ -22,4 +22,7 @@ secrets/* !secrets/.keep tests/dist/* -src/i18n/keysets \ No newline at end of file +src/i18n/keysets + +tests/metadata +tests/certs \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml deleted file mode 100644 index e69de29bb2..0000000000 diff --git a/tests/backend-configs/api.yaml b/tests/backend-configs/api.yaml new file mode 100644 index 0000000000..55ef7acdbf --- /dev/null +++ b/tests/backend-configs/api.yaml @@ -0,0 +1,37 @@ +--- +CONNECTORS: + CHYT: + CONN_CHYT_DEFAULT_CLIQUE: '*ch_public' + CONN_CHYT_FORBIDDEN_CLIQUES: [] + CONN_CHYT_PUBLIC_CLIQUES: [] +CONNECTOR_AVAILABILITY: + sections: [] + uncategorized: + - availability: free + conn_type: clickhouse + - availability: free + conn_type: postgres + - availability: free + conn_type: chyt + visible_connectors: [] +CORS_ALLOWED_HEADERS: +- Content-Type +- X-Request-ID +- X-DL-TenantId +- X-CSRF-Token +- X-DL-Allow-Superuser +- X-DL-Sudo +CORS_ALLOWED_ORIGINS: +- '*' +CORS_EXPOSE_HEADERS: +- X-Request-ID +CSRF_HEADER_NAME: X-CSRF-Token +CSRF_METHODS: +- POST +- PUT +- DELETE +CSRF_TIME_LIMIT: 43200 +DL_CRY_ACTUAL_KEY_ID: '0' +DL_CRY_KEYMAP: {} +SENTRY_DSN_DATASET_API: '' +SENTRY_ENABLED: false diff --git a/tests/data/superstore-sales.sql b/tests/data/sales-db.sql similarity index 72% rename from tests/data/superstore-sales.sql rename to tests/data/sales-db.sql index 34c6745b27..76aaae84f5 100644 --- a/tests/data/superstore-sales.sql +++ b/tests/data/sales-db.sql @@ -29,27 +29,7 @@ CREATE TABLE sales ( sales TEXT NOT NULL ); -COPY sales ( - id, - order_id, - order_date, - ship_date, - ship_mode, - customer_id, - customer_name, - segment, - country, - city, - state, - postal_code, - region, - product_id, - category, - sub_category, - product_name, - sales -) -FROM './superstore_sales.csv' DELIMITER ',' CSV HEADER; +COPY sales FROM '/docker-entrypoint-initdb.d/superstore-sales.csv' DELIMITER ',' CSV HEADER; ALTER TABLE ONLY sales ADD CONSTRAINT sales_pkey PRIMARY KEY (id); diff --git a/tests/data/superstore_sales.csv b/tests/data/superstore-sales.csv similarity index 100% rename from tests/data/superstore_sales.csv rename to tests/data/superstore-sales.csv diff --git a/tests/data/us-e2e-data b/tests/data/us-e2e-data new file mode 100644 index 0000000000..30f81076b0 --- /dev/null +++ b/tests/data/us-e2e-data @@ -0,0 +1,9 @@ +INSERT INTO public.workbooks VALUES (1540491943966934028, 'E2E Workbook', 'A workbook for running E2E tests', NULL, 'common', '{}', 'systemId', '2023-10-27 08:22:30.193066+00', NULL, false, NULL, NULL, 'systemId', '2023-10-27 08:22:30.193066+00', 'e2e workbook', '\x4500313132004520576f726b626f6f6b'); + +INSERT INTO public.entries VALUES ('connection', 'postgres', '1542786167294919702/connection', NULL, 'uid:systemId', '2023-10-30 12:20:42.924999+00', 'uid:systemId', '2023-10-30 12:20:42.924999+00', false, NULL, false, '1542786167294919702/Connection', 1542786167294919702, 1542786167294919703, NULL, 'common', 'connection', '\x636f6e6e656374696f6e', false, '{"password": {"key_id": "key_1", "key_kind": "local_fernet", "cypher_text": "gAAAAABlP5-aKeOxaN8_TTXHMaiJHHxshYLCK6oEsrzt9oY0rCR4wjeHZLzmQa_x0J2ojkCxJ4QINAQqB8X4zJ5vJrcqOecTlA=="}}', 1540491943966934028); +INSERT INTO public.entries VALUES ('dataset', '', '1542786306705196056/dataset', NULL, 'uid:systemId', '2023-10-30 12:20:59.55005+00', 'uid:systemId', '2023-10-30 12:20:59.55005+00', false, NULL, false, '1542786306705196056/Dataset', 1542786306705196056, 1542786306705196057, NULL, 'common', 'dataset', '\x64617461736574', false, '{}', 1540491943966934028); + +INSERT INTO public.revisions VALUES ('{"host": "postgres-e2e", "name": null, "port": 5432, "ssl_ca": null, "db_name": "sales", "username": "e2e", "ssl_enable": false, "table_name": null, "cache_ttl_sec": null, "raw_sql_level": "dashsql", "enforce_collate": "auto", "sample_table_name": null, "data_export_forbidden": false}', '{"state": "saved"}', 'uid:systemId', '2023-10-30 12:20:42.924999+00', 'uid:systemId', '2023-10-30 12:20:42.924999+00', 1542786167294919703, 1542786167294919702, '{}'); +INSERT INTO public.revisions VALUES ('{"rls": [], "name": "", "revision_id": null, "result_schema": [{"cast": "integer", "guid": "id", "type": "DIMENSION", "title": "id", "valid": true, "hidden": false, "source": "id", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "integer", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "integer", "has_auto_aggregation": false}, {"cast": "string", "guid": "order_id", "type": "DIMENSION", "title": "order_id", "valid": true, "hidden": false, "source": "order_id", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "date", "guid": "order_date", "type": "DIMENSION", "title": "order_date", "valid": true, "hidden": false, "source": "order_date", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "date", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "date", "has_auto_aggregation": false}, {"cast": "date", "guid": "ship_date", "type": "DIMENSION", "title": "ship_date", "valid": true, "hidden": false, "source": "ship_date", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "date", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "date", "has_auto_aggregation": false}, {"cast": "string", "guid": "ship_mode", "type": "DIMENSION", "title": "ship_mode", "valid": true, "hidden": false, "source": "ship_mode", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "customer_id", "type": "DIMENSION", "title": "customer_id", "valid": true, "hidden": false, "source": "customer_id", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "customer_name", "type": "DIMENSION", "title": "customer_name", "valid": true, "hidden": false, "source": "customer_name", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "segment", "type": "DIMENSION", "title": "segment", "valid": true, "hidden": false, "source": "segment", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "country", "type": "DIMENSION", "title": "country", "valid": true, "hidden": false, "source": "country", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "city", "type": "DIMENSION", "title": "city", "valid": true, "hidden": false, "source": "city", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "state", "type": "DIMENSION", "title": "state", "valid": true, "hidden": false, "source": "state", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "postal_code", "type": "DIMENSION", "title": "postal_code", "valid": true, "hidden": false, "source": "postal_code", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "region", "type": "DIMENSION", "title": "region", "valid": true, "hidden": false, "source": "region", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "product_id", "type": "DIMENSION", "title": "product_id", "valid": true, "hidden": false, "source": "product_id", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "category", "type": "DIMENSION", "title": "category", "valid": true, "hidden": false, "source": "category", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "sub_category", "type": "DIMENSION", "title": "sub_category", "valid": true, "hidden": false, "source": "sub_category", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "product_name", "type": "DIMENSION", "title": "product_name", "valid": true, "hidden": false, "source": "product_name", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}, {"cast": "string", "guid": "sales", "type": "DIMENSION", "title": "sales", "valid": true, "hidden": false, "source": "sales", "formula": "", "avatar_id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "calc_mode": "direct", "data_type": "string", "managed_by": "user", "aggregation": "none", "description": "", "guid_formula": "", "default_value": null, "lock_aggregation": false, "value_constraint": null, "initial_data_type": "string", "has_auto_aggregation": false}], "source_avatars": [{"id": "c5722360-771e-11ee-8e59-ebba6a1f8b16", "title": "public.sales", "valid": true, "is_root": true, "source_id": "c5722361-771e-11ee-8e59-ebba6a1f8b16", "managed_by": "user"}], "avatar_relations": [], "component_errors": {"items": []}, "result_schema_aux": {"inter_dependencies": {"deps": []}}, "obligatory_filters": [], "source_collections": [{"id": "c5722361-771e-11ee-8e59-ebba6a1f8b16", "type": "collection", "title": "sales", "valid": true, "origin": {"parameters": {"db_version": "PostgreSQL 13.12 on aarch64-unknown-linux-musl, compiled by gcc (Alpine 12.2.1_git20220924-r10) 12.2.1 20220924, 64-bit", "table_name": "sales", "schema_name": "public"}, "raw_schema": [{"name": "id", "type": "integer", "title": "id", "nullable": false, "description": "", "native_type": {"name": "integer", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "order_id", "type": "string", "title": "order_id", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "order_date", "type": "date", "title": "order_date", "nullable": false, "description": "", "native_type": {"name": "date", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "ship_date", "type": "date", "title": "ship_date", "nullable": false, "description": "", "native_type": {"name": "date", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "ship_mode", "type": "string", "title": "ship_mode", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "customer_id", "type": "string", "title": "customer_id", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "customer_name", "type": "string", "title": "customer_name", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "segment", "type": "string", "title": "segment", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "country", "type": "string", "title": "country", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "city", "type": "string", "title": "city", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "state", "type": "string", "title": "state", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "postal_code", "type": "string", "title": "postal_code", "nullable": true, "description": "", "native_type": {"name": "text", "nullable": true, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "region", "type": "string", "title": "region", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "product_id", "type": "string", "title": "product_id", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "category", "type": "string", "title": "category", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "sub_category", "type": "string", "title": "sub_category", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "product_name", "type": "string", "title": "product_name", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}, {"name": "sales", "type": "string", "title": "sales", "nullable": false, "description": "", "native_type": {"name": "text", "nullable": false, "conn_type": "postgres", "native_type_class_name": "common_native_type"}, "lock_aggregation": false, "has_auto_aggregation": false}], "created_from": "PG_TABLE", "connection_id": "dr0y3yyi1gjk2"}, "sample": null, "managed_by": "user", "materialization": null}]}', '{"created_via": "user"}', 'uid:systemId', '2023-10-30 12:20:59.55005+00', 'uid:systemId', '2023-10-30 12:20:59.55005+00', 1542786306705196057, 1542786306705196056, '{"c5722361-771e-11ee-8e59-ebba6a1f8b16": "dr0y3yyi1gjk2"}'); + +INSERT INTO public.links VALUES (1542786306705196056, 1542786167294919702, 'c5722361-771e-11ee-8e59-ebba6a1f8b16'); \ No newline at end of file diff --git a/tests/docker-compose.e2e.yml b/tests/docker-compose.e2e.yml new file mode 100644 index 0000000000..0bd1231eae --- /dev/null +++ b/tests/docker-compose.e2e.yml @@ -0,0 +1,123 @@ +version: "3.7" + +services: + pg-compeng: + container_name: datalens-pg-compeng + image: postgres:13-alpine + environment: + POSTGRES_PASSWORD: "postgres" + POSTGRES_DB: postgres + POSTGRES_USER: postgres + + control-api: + container_name: datalens-control-api + image: ghcr.io/datalens-tech/datalens-control-api:0.2037.0 + environment: + BI_API_UWSGI_WORKERS_COUNT: 4 + CONNECTOR_AVAILABILITY_VISIBLE: "clickhouse,postgres,chyt" + RQE_FORCE_OFF: 1 + DL_CRY_ACTUAL_KEY_ID: key_1 + DL_CRY_KEY_VAL_ID_key_1: "h1ZpilcYLYRdWp7Nk8X1M1kBPiUi8rdjz9oBfHyUKIk=" + RQE_SECRET_KEY: "" + US_HOST: "http://us" + US_MASTER_TOKEN: "fake-us-master-token" + CONFIG_PATH: "/etc/backend-configs/api.yaml" + ports: + - 8081:8080 + depends_on: + - us + volumes: + - ./backend-configs:/etc/backend-configs + + data-api: + container_name: datalens-data-api + image: ghcr.io/datalens-tech/datalens-data-api:0.2037.0 + environment: + GUNICORN_WORKERS_COUNT: 5 + RQE_FORCE_OFF: 1 + CACHES_ON: 0 + MUTATIONS_CACHES_ON: 0 + RQE_SECRET_KEY: "" + DL_CRY_ACTUAL_KEY_ID: key_1 + DL_CRY_KEY_VAL_ID_key_1: "h1ZpilcYLYRdWp7Nk8X1M1kBPiUi8rdjz9oBfHyUKIk=" + BI_COMPENG_PG_ON: 1 + BI_COMPENG_PG_URL: "postgresql://postgres:postgres@pg-compeng:5432/postgres" + US_HOST: "http://us" + US_MASTER_TOKEN: "fake-us-master-token" + CONFIG_PATH: "/etc/backend-configs/api.yaml" + ports: + - 8082:8080 + depends_on: + - us + - pg-compeng + volumes: + - ./backend-configs:/etc/backend-configs + + pg-us: + container_name: datalens-pg-us + image: postgres:13-alpine + environment: + POSTGRES_DB: us-db-ci_purgeable + POSTGRES_USER: us + POSTGRES_PASSWORD: us + volumes: + - ./metadata:/var/lib/postgresql/data + + postgres-e2e: + container_name: postgres-e2e + image: postgres:13-alpine + environment: + POSTGRES_PASSWORD: "e2e" + POSTGRES_DB: sales + POSTGRES_USER: e2e + volumes: + - e2e-data-volume:/docker-entrypoint-initdb.d + + us: + container_name: datalens-us + image: ghcr.io/datalens-tech/datalens-us:0.107.0 + depends_on: + - pg-us + environment: + APP_INSTALLATION: "opensource" + APP_ENV: "prod" + MASTER_TOKEN: "fake-us-master-token" + POSTGRES_DSN_LIST: ${METADATA_POSTGRES_DSN_LIST:-postgres://us:us@pg-us:5432/us-db-ci_purgeable} + SKIP_INSTALL_DB_EXTENSIONS: ${METADATA_SKIP_INSTALL_DB_EXTENSIONS:-0} + USE_DEMO_DATA: 0 + USE_E2E_MOCK_DATA: 1 + HC: ${HC:-0} + NODE_EXTRA_CA_CERTS: /certs/root.crt + ports: + - "50500:80" + extra_hosts: + - "host.docker.internal:host-gateway" + volumes: + - ./certs:/certs + - e2e-data-volume:/opt/e2e-data + + datalens: + container_name: datalens-ui + build: + dockerfile: Dockerfile + context: ../ + network: host + ports: + - 8080:80 + depends_on: + - us + - control-api + - data-api + - postgres-e2e + environment: + APP_MODE: "full" + APP_ENV: "production" + APP_INSTALLATION: "opensource" + AUTH_POLICY: "disabled" + NODE_EXTRA_CA_CERTS: "/usr/local/share/ca-certificates/cert.pem" + HC: ${HC:-0} + volumes: + - e2e-data-volume:/opt/app/tests/data + +volumes: + e2e-data-volume: \ No newline at end of file diff --git a/tests/docker-compose.override.yml b/tests/docker-compose.override.yml deleted file mode 100644 index 2623f69dff..0000000000 --- a/tests/docker-compose.override.yml +++ /dev/null @@ -1,8 +0,0 @@ -version: "3.7" - -services: - datalens: - build: - context: ../datalens-ui - dockerfile: ../datalens-ui/Dockerfile - image: result/latest