myscript_module's People
Forkers
rcchan5myscript_module's Issues
Mark script completion
do a demo using the wait function, to show that the program will wait for the script to finish.
IF it doesn't, then remove the line to add the _Success file, and make that part of the user script.
add a line to the script that does
#start of script
touch script.sh_Started
...
#end of script
touch script.sh_Success
This may just be a requirement for user scripts.
We could probably add a bit of code in checkDependencies() to check that a line like this is present, and if it is not suggest a line to the user.
Depending on the launch command,
Please modify script [script.sh] to include the following line at the end of the script, or the end of the main method:
if bash: touch script.sh_Success
if R: system("touch script.sh_Success")
if python:
Verify the launch option
The config option:
myScript.launcher=
is intended for things like "python", or "Rscript". Default is none (ie, bash)
It up to the user to make sure that the launch command is available in the running environment (cluster module, or local install, or docker image, etc).
Verify that this is working for "python" and "Rscript" and "Rscript -knit" (or whatever the arg is for knitting a markdown from the command line). Make corresponding demos, similar to the "someUserScript.sh" example.
allow for resources
With config:
myScript.resources=path/to/myFavLib.sh, path/leading/to/image.png, otherFile.weird, refTable.txt
or
myScript.resources=path/to/dir
Each resource will be copied to top level of module resources folder.
If a directory is supplied, the contents of that directory will be pulled in.
They can be called from the imported script using "../resources/"
Python support functions to match R support
default docker image
In an upcoming change to the docker utility, modules will have to implement a method to return the docker image they need.
getDockerImage()
This probably create a general config property (docker.dockerImage=) that can be supplied in a module-specific form (myScript.dockerImage=), so the user will be able to supply the appropriate docker image for their script to run in.
Once that change is made, this module will need to implement the method.
99.9% of the time, the scripts our users supply will be one of bash, python, R, or java.
We can determine which of those it is based on the launch command or the file extension of the script. IF there is no docker image given in the config file, the method should choose one of the biolockj docker images (blj_basic_python, blj_basic_bash etc).
If it is run in docker mode without a configured docker image, so it has to use a default, it should give a info/warning message saying which image is used and why. We might also say that if this is the desired container to please put that in the config file.
examine permission requirements
running
file.setExecutable(true, false)
was not enough to run the script.
setting the file permissions with chmod a+x before the program started
was enough for the script to run.
If users make the file executable, will that always work?
What about the resources? Will they preserve their original permissions?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. ๐๐๐
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google โค๏ธ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.