Skip to content

Commit a8ba578

Browse files
committed
Allow user/pass on stdio transport
1 parent f5e2f09 commit a8ba578

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

src/mcp_server_uyuni/server.py

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,7 @@ class ActivationKeySchema(BaseModel):
3131
activation_key: str
3232

3333
REQUIRED_VARS = [
34-
"UYUNI_SERVER",
35-
"UYUNI_USER",
36-
"UYUNI_PASS",
34+
"UYUNI_SERVER"
3735
]
3836

3937
missing_vars = [key for key in REQUIRED_VARS if key not in os.environ]
@@ -136,8 +134,8 @@ async def _call_uyuni_api(
136134
if perform_login:
137135
try:
138136
if token:
139-
login_response = await client.post(
140-
UYUNI_SERVER + '/rhn/manager/api/oidcLogin',
137+
login_response = await client.get(
138+
UYUNI_SERVER + '/rhn/manager/api/auth/oidcLogin',
141139
headers={"Authorization": f"Bearer {token}"})
142140
elif UYUNI_USER and UYUNI_PASS:
143141
login_response = await client.post(

0 commit comments

Comments
 (0)