-
Notifications
You must be signed in to change notification settings - Fork 73
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
fix(jans-tui): Saving a script as a file is not working #9979
Comments
@maduvena @pujavs I added a test script. This is what TUI sent to config-api {
"inum": "",
"scriptType": "application_session",
"enabled": false,
"name": "test",
"description": "test",
"locationType": "file",
"locationPath": "/opt/jans/python/libs/a.py",
"programmingLanguage": "python",
"level": 0,
"internal": false,
"modified": false,
"revision": 1,
"script": "import os\nfor i in os.listdir('/tmp'):\n print(i)",
"moduleProperties": [
{
"value1": "location_type",
"value2": "file"
}
]
} It seems config-api ignores location. It saves to database. Here is stored script |
That is correct |
Behavior explained in this issue is opposite to initial idea of using When we use file location type we follow next steps:
Why instead of modifying script file you call config-api? This not really uses this location type in this case. It's looks like DB location type is better conform this. |
@yurem What do you think about removing location type from TUI. |
@devrimyatar if we remove it from TUI we can't add script with this location type. And we will loss this functionality. @pujavs @devrimyatar what do you think about changing this part of request:
to:
After getting this request config-api should build Also developers still can use |
Describe the bug
Scripts can be saved in db or as a file. The file option is not working.
Tested on Local VM, I dont know how this will translate on Cloud.
To Reproduce
Steps to reproduce the behavior:
The text was updated successfully, but these errors were encountered: