Hi Henrique,
Thanks.
I used the maven-wolifecyle-plugin 2.1-SNAPSHOT and it did have the executable bit set on the files one gets derived from the *tar.gz artifacts.
However, it also set the executable bit on all the files. I am not a security expert, but in general, I think you want to only set the execute bit on 2 files inside the myapp.woapplication.tar.gz. The myapp.woa that maven builds is correct, as far as I have looked and can tell. It would have:
myapp.woa/
myapp << is a /bin/sh script, should have the executable bit set
myapp.cmd << windows launcher, it uses extensions not an executable bit, so " .EXE, .COM, .CMD, or .BAT." can execute.
Contents/
MacOS/
myapp << again the same unix /bin/sh script, should have the executable bit set
When the myapp.woa gets transformed into the myapp.woapplication.tar.gz those /bin/sh scripts, which are used to launch the app on a unix platform, did loose their executable bit. I don't know why tar-ing the myapp.woa would drop the bits; its not a standard tar program is it? Is that tar-ing program the culprit?
I don't think the myapp.wowebserverresources.tar.gz should have, nor need, any executable bits set. (I didn't check that one.. yet.)
Thanks,
Greg
On Jan 20, 2010, at 9:40 AM, Henrique Prange wrote:
> Hi Mr. Brown,
>
> I've committed a fix. You can change the version of maven-wolifecyle-plugin to 2.1-SNAPSHOT and check if it works? Remember the -U option to update SNAPSHOTs.
>
> mvn -U clean package
>
> I'll make a new release of this plug-in soon.
>
> Cheers,
>
> Henrique
>
> On 18/01/10 14:28, Henrique Prange wrote:
>> Hi Brown,
>>
>> I've created the issue WOL-1140 [1] to address this problem. Thanks for
>> reporting.
>>
>> [1]http://issues.objectstyle.org/jira/browse/WOL-1140
>>
>> Cheers,
>>
>> Henrique
>>
>> On 18/01/10 13:00, Mr. G Brown wrote:
>>> Hi folks,
>>>
>>> Maven produces ziptards ( ziptard, noun, a compressed representation of
>>> a directory produced by tar-ing and gzipping the tar representaion of
>>> the directory) of one's application, which doesn't have the necessary
>>> executable bits set on the shell script that launches the application.
>>>
>>> If one unzips and un-tars the maven produced artifact, it won't launch.
>>> However, in the /target directory, the application.WOA, has the
>>> executable bit set on the script. If you look further into the ziptard's
>>> unzipped application in the directory /contents/MacOS/Launch-script,
>>> that script also does not have the executable bit set.
>>>
>>> Mr. Wotaskd is having a difficult day.
>>>
>>> Should not these bits be set? Ziptards seem like a good way to copy the
>>> app and resources around. Is there a reason they should not be set?
>>>
>>> Thanks,
>>>
>>> <archetype>
>>> <groupId>org.objectstyle.woproject.maven2
>>> </groupId>
>>> <artifactId>woapplication-archetype
>>> </artifactId>
>>> <version>2.1</version>
>>> <description>WebObjects Application Archetype</description>
>>> </archetype>
>>> Mr. G Brown
>>> gsbrow..mich.edu <mailto:gsbrown@umich.edu>
>>>
>>>
>>>
Mr. G Brown
gsbrow..mich.edu
This archive was generated by hypermail 2.0.0 : Fri Jan 22 2010 - 09:44:47 EST