Skip to content

Commit

Permalink
Fixed #22
Browse files Browse the repository at this point in the history
  • Loading branch information
khoroshevskyi committed Jan 16, 2024
1 parent 7a89e24 commit 385ddeb
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
3 changes: 3 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,9 @@ Additionally, our client supports pephub authorization.
The authorization process is based on pephub device authorization protocol.
To upload projects or to download private projects, user must be authorized through pephub.

If you want to use your own pephub instance, you can specify it by setting `PEPHUB_BASE_URL` environment variable.
e.g. `export PEPHUB_BASE_URL=https://pephub.databio.org` (This is original pephub instance)

To login, use the `login` argument; to logout, use `logout`.

----
Expand Down
3 changes: 2 additions & 1 deletion pephubclient/constants.py
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
from enum import Enum
from typing import Optional
import os

import pydantic
from pydantic import BaseModel

PEPHUB_BASE_URL = "https://pephub.databio.org/"
PEPHUB_BASE_URL = os.getenv("PEPHUB_BASE_URL", default="https://pephub.databio.org/")
# PEPHUB_BASE_URL = "http://0.0.0.0:8000/"
PEPHUB_PEP_API_BASE_URL = f"{PEPHUB_BASE_URL}api/v1/projects/"
PEPHUB_PEP_SEARCH_URL = f"{PEPHUB_BASE_URL}api/v1/namespaces/{{namespace}}/projects"
Expand Down

0 comments on commit 385ddeb

Please sign in to comment.