Skip to content

Commit fa51a20

Browse files
Merge pull request #30 from pepkit/dev
Fixed #22
2 parents bd1307b + f0ac5a7 commit fa51a20

File tree

4 files changed

+10
-2
lines changed

4 files changed

+10
-2
lines changed

README.md

+3
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,9 @@ Additionally, our client supports pephub authorization.
1616
The authorization process is based on pephub device authorization protocol.
1717
To upload projects or to download private projects, user must be authorized through pephub.
1818

19+
If you want to use your own pephub instance, you can specify it by setting `PEPHUB_BASE_URL` environment variable.
20+
e.g. `export PEPHUB_BASE_URL=https://pephub.databio.org` (This is original pephub instance)
21+
1922
To login, use the `login` argument; to logout, use `logout`.
2023

2124
----

docs/changelog.md

+4
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,10 @@
22

33
This project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html) and [Keep a Changelog](https://keepachangelog.com/en/1.0.0/) format.
44

5+
## [0.2.2] - 2024-01-06
6+
### Added
7+
- customization of the base pephub URL. [#22](https://github.com/pepkit/pephubclient/issues/22)
8+
59
## [0.2.1] - 2023-11-01
610
### Added
711
- is_registry_path checker function

pephubclient/__init__.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
from pephubclient.pephubclient import PEPHubClient
22

33
__app_name__ = "pephubclient"
4-
__version__ = "0.2.1"
4+
__version__ = "0.2.2"
55
__author__ = "Oleksandr Khoroshevskyi, Rafal Stepien"
66

77

pephubclient/constants.py

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
from enum import Enum
22
from typing import Optional
3+
import os
34

45
import pydantic
56
from pydantic import BaseModel
67

7-
PEPHUB_BASE_URL = "https://pephub.databio.org/"
8+
PEPHUB_BASE_URL = os.getenv("PEPHUB_BASE_URL", default="https://pephub.databio.org/")
89
# PEPHUB_BASE_URL = "http://0.0.0.0:8000/"
910
PEPHUB_PEP_API_BASE_URL = f"{PEPHUB_BASE_URL}api/v1/projects/"
1011
PEPHUB_PEP_SEARCH_URL = f"{PEPHUB_BASE_URL}api/v1/namespaces/{{namespace}}/projects"

0 commit comments

Comments
 (0)