Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Minimal path change needed for galaxy PR 16795 #114

Merged
merged 2 commits into from
Nov 9, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion docs/installation.rst
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ The following options in the ``gravity`` section of ``galaxy.yml`` can be used t
# enable: false

# gx-it-proxy version
# version: '>=0.0.5'
# version: '>=0.0.6'

# Public-facing IP of the proxy
# ip: localhost
Expand Down
2 changes: 1 addition & 1 deletion gravity/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
from pydantic import BaseModel, BaseSettings, Extra, Field, validator

DEFAULT_INSTANCE_NAME = "_default_"
GX_IT_PROXY_MIN_VERSION = "0.0.5"
GX_IT_PROXY_MIN_VERSION = "0.0.6"


def none_to_default(cls, v, field):
Expand Down
2 changes: 1 addition & 1 deletion gravity/state.py
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ def __init__(self, *args, **kwargs):
it_base_path = self.config.app_config.get("interactivetools_base_path", "/")
it_base_path = "/" + f"/{it_base_path.strip('/')}/".lstrip("/")
it_prefix = self.config.app_config.get("interactivetools_prefix", "interactivetool")
self.settings["proxy_path_prefix"] = f"{it_base_path}{it_prefix}/access/interactivetoolentrypoint"
self.settings["proxy_path_prefix"] = f"{it_base_path}{it_prefix}/ep"

@validator("settings")
def _validate_settings(cls, v, values):
Expand Down
4 changes: 2 additions & 2 deletions tests/test_process_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ def test_gxit_handler(default_config_manager, galaxy_yml, gxit_config, process_m
sessions = "database/interactivetools_map.sqlite"
gxit_config_contents = gxit_config_path.read_text()
assert f'npx gx-it-proxy@>={GX_IT_PROXY_MIN_VERSION} --ip localhost --port {gxit_port} --sessions {sessions}' in gxit_config_contents
assert '--proxyPathPrefix /interactivetool/access/interactivetoolentrypoint' in gxit_config_contents
assert '--proxyPathPrefix /interactivetool/ep' in gxit_config_contents


@pytest.mark.parametrize('process_manager_name', ['supervisor', 'systemd'])
Expand All @@ -344,7 +344,7 @@ def test_gxit_handler_path_prefix(default_config_manager, galaxy_yml, gxit_confi
pm.update()
gxit_config_path = service_conf_path(state_dir, process_manager_name, 'gx-it-proxy')
assert gxit_config_path.exists()
proxy_path_prefix = f'{gxit_base_path}{gxit_prefix}/access/interactivetoolentrypoint'
proxy_path_prefix = f'{gxit_base_path}{gxit_prefix}/ep'
assert f'--proxyPathPrefix {proxy_path_prefix}' in gxit_config_path.read_text()


Expand Down
Loading