Like a web service #150
Replies: 2 comments
-
Dear @christophgil, I unfortunately have to admit my expertise with web deployment is also very limited. I have tried to implement a few of your suggestions, but they should be used with EXTREME CAUTION as this might expose your system to severe vulnerabilities and security issues!!! In brief,
@echo off
SET user=username
SET server=servername
SET alphatims_executable=full_remote_path_to_alphatims
echo Provided file: "%~1"
echo User: %user%
echo Server: %server%
echo Alphatims executable: %alphatims_executable%
ssh -X %user%@%server% "%alphatims_executable% gui --bruker_raw_data $(echo '%~1' | tr '\\' '/')"
pause I also implemented automatic removal of starting and trailing double quotes from paths provided to the alphatims gui. The automatic swapping of forward backslashes is not included (in AlphaTims itself, but it is in the bat script above), as I believe this generally is confusing enough for most people and hopefully most will probably not mix unix and windows paths too often. I will not release these updates properly right now, but you can install and them on your linux machine with: conda create -n alphatims_develop python=3.8 -y
conda activate alphatims_develop
pip install "git+https://github.com/MannLabs/alphatims.git@gui#egg=alphatims[plotting]"
#and to find your executable binary for the bat script
which alphatims I would be happy to receive any feedback if this actually works for you and your users on your setup. Best, |
Beta Was this translation helpful? Give feedback.
-
Dear Sander,
Thanks so much,
This is exactly what I needed.
I will try this next week.
Cheers
Christoph
…On Mon, Aug 23, 2021 at 4:23 PM Sander Willems ***@***.***> wrote:
Dear @christophgil <https://github.com/christophgil>,
I unfortunately have to admit my expertise with web deployment is also
very limited. I have tried to implement a few of your suggestions, but they
should be used with EXTREME CAUTION as this might expose your system to
severe vulnerabilities and security issues!!!
In brief,
- running the AlphaTims command line (alphatims gui) now has an option
"port" which can be set and which allows outside access to your system.
Note that files still need to be present on the host server and that no
files can actually be "uploaded" between machines. Als note that this only
instantiates a single instamce of the alphatims gui. Once a connection is
opened by a user, the host will automatic close if the user closes their
browser tab. Furthermore, notice that the url can be copy-pasted and that
actually can actually see real-time updates as users change their
selections.
- running the AlphaTims command line (alphatims gui) now has an option
"bruker_raw_data", which allows to open the gui directly with a sample
file. Since our internal system structure is different than yours, I can
not fully test the code below that hopefully gives you inspiration on how
to create a "drag-and-drop your files on a bat script to instantiate a
remote alphatims gui instance":
@echo off
SET user=usernameSET server=servernameSET alphatims_executable=full_remote_path_to_alphatims
echo Provided file: "%~1"echo User: %user%echo Server: %server%echo Alphatims executable: %alphatims_executable%
ssh -X %user%@%server% "%alphatims_executable% gui --bruker_raw_data $(echo '%~1' | tr '\\' '/')"pause
I also implemented automatic removal of starting and trailing double
quotes from paths provided to the alphatims gui. The automatic swapping of
forward backslashes is not included (in AlphaTims itself, but it is in the
bat script above), as I believe this generally is confusing enough for most
people and hopefully most will probably not mix unix and windows paths too
often.
I will not release these updates properly right now, but you can install
and them on your linux machine with:
conda create -n alphatims_develop python=3.8 -y
conda activate alphatims_develop
pip install ***@***.***#egg=alphatims[plotting]"#and to find your executable binary for the bat script
which alphatims
I would be happy to receive any feedback if this actually works for you
and your users on your setup.
Best,
Sander
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#150 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ASRZU6GCUGVZDTL2D6PBPD3T6JKVVANCNFSM5CTCYQFA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&utm_campaign=notification-email>
.
|
Beta Was this translation helpful? Give feedback.
-
Many thanks for this nice tools.
It seems that our Windows Desktop PCs have too little RAM for our big brukertimstof files and therefore
I have successfully installed alphatims on a Ubuntu server for all colleagues.
My colleagues login into Ubuntu via x2go and start alphatims gui in Firefox Browser.
I wonder whether it would be possible to run alphatims on the Ubuntu server and display the html5 GUI in the web browser of the Windows desktop PC.
This would not require x2go.
It could work similar like a shiny app or a web server CGI or php.
I must admit that I am not familiar with bokeh and tornado.
To my poor understanding and from what I learned from the bokeh page,
it would be sufficient to
start the bokeh on the server with something like
bokeh serve path-to-alphatims
HOW COULD MY COLLEAGUES USE IT:
Posixified UNC paths on our Windows desktop computers are valid paths on the Ubuntu when the leading double slash is
replaced by a single one. Symlinks make this happen. So it would be convenient and possible to browse the file tree and to enter paths to server side alphatims.
Or another way to use it would be a windows bat script where the path of the .d file could be dragged on to start alphatims gui.
FURTHER SUGGESTIONS:
With Shift-context menu in File-Explorer, one can copy file paths to clipboard and paste it into alphatims.
Currently, In alphatims the user needs remove the double quotes and
if used on Linux convert backslash to regular slash.
Could this be done by alphatims automatically?
In the install instruction you could give additional information:
Many thanks
Christoph
Beta Was this translation helpful? Give feedback.
All reactions