Run gpfjs frontend with impala from e2e container

  1. Remove apache, if you have one and don’t use it (https://askubuntu.com/questions/176964/permanently-removing-apache2/387793#387793)

  2. Run ./gpf-e2e/build_setup

  3. Run docker exec -it {CONTAINER_ID} /bin/bash by replacing the container id with your registry.seqpipe.org/seqpipe-gpf-full:master(...) container id

  4. In the container:

cd /opt/conda/envs/gpf/lib/python3.8/site-packages/wdae
vi settings.py
  • And add the following lines to the end:

ALLOWED_HOSTS += ["localhost"]

INSTALLED_APPS += [
    "corsheaders",
    "django_extensions",
]

MIDDLEWARE += [
    "corsheaders.middleware.CorsMiddleware",
    "django.middleware.common.CommonMiddleware",
]

CORS_ORIGIN_WHITELIST = [
    "http://localhost:8000",
    "http://127.0.0.1:9000",
    "http://localhost:4200",
    "http://127.0.0.1:4200",
]

CORS_ALLOW_CREDENTIALS = True
  • Run supervisorctl restart gpf

  • exit the container

  1. Edit gpfjs/src/environments/environment.ts

const basePath = 'http://localhost:9001';
  1. Optional step for e2e url tests:

  • Edit gpfjs/src/app/app.module.ts

  • Add this line to the top of the file:

import { APP_BASE_HREF } from '@angular/common';
  • Add this to your @NgModule provider section:

[{provide: APP_BASE_HREF, useValue: '/gpf'}]