A
andoni.oconchubhair
Hello,
I have written a Java program which does some calculations and prints
the results to Standard Out/System Out. It is packaged inside a .jar
file. I call this program from a .sh file so that I can set up the
CLASSPATH and some parameters. Then I put an 'alias' entry in /etc/
profile so that I can use one command to run the program from any user
without them knowing the path.
This all worked fine until I went to make my program configurable. I
added a 'config.properties' file with some data. The program will now
only work if set the ownership of config.properties to my user:group
(an then only work for me) or if I put the full path to
config.properties into the Java code.
Can anyone please tell me why the relative path won't work if anyone
but the owner of the file is using the program? I have given full
permissions to all these files and still no joy.
Thanks for any suggestions.
Andoni.
I have written a Java program which does some calculations and prints
the results to Standard Out/System Out. It is packaged inside a .jar
file. I call this program from a .sh file so that I can set up the
CLASSPATH and some parameters. Then I put an 'alias' entry in /etc/
profile so that I can use one command to run the program from any user
without them knowing the path.
This all worked fine until I went to make my program configurable. I
added a 'config.properties' file with some data. The program will now
only work if set the ownership of config.properties to my user:group
(an then only work for me) or if I put the full path to
config.properties into the Java code.
Can anyone please tell me why the relative path won't work if anyone
but the owner of the file is using the program? I have given full
permissions to all these files and still no joy.
Thanks for any suggestions.
Andoni.