tycho-gpg-plugin:sign-p2-artifacts needs to go between tycho-p2-repository-plugin:tycho-p2-repository-plugin and tycho-p2-repository-plugin:archive-repository #2992
-
Hi, Is there a better way to made gpg signing before making the archive, we implemented a workaround (as it is shown in the following pease of xml), is this the way to do it? if it is I think that this could be improved. What do you think? ...
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-p2-repository-plugin</artifactId>
<executions>
<execution>
<id>default-assemble-repository</id>
<goals>
<goal>assemble-repository</goal>
</goals>
<phase>package</phase>
</execution>
<execution>
<id>default-archive-repository</id>
<goals>
<goal>archive-repository</goal>
</goals>
<phase>pre-integration-test</phase>
</execution>
</executions>
<configuration>
...
</configuration>
</plugin>
<plugin>
<groupId>org.eclipse.tycho</groupId>
<artifactId>tycho-gpg-plugin</artifactId>
<executions>
<execution>
<id>gpgsigner</id>
<goals>
<goal>sign-p2-artifacts</goal>
</goals>
<configuration>
<verbose>true</verbose>
<skipIfJarsigned>true</skipIfJarsigned>
<passphrase>${gpg.passphrase}</passphrase>
<gpgArguments>
<arg>--verbose</arg>
</gpgArguments>
</configuration>
<phase>package</phase>
</execution>
</executions>
</plugin>
... |
Beta Was this translation helpful? Give feedback.
Replies: 3 comments 9 replies
-
The fact that the archived repo is missing PGP signatures is actually an issue in Tycho. You may want to open an issue for it so this can be improved in Tycho directly. Thinking further about it, the pgp sign mojo could be built-in the default lifecycle for In the meantime, yes, I think this workaround a good-ish way to do it ("whatever works"). |
Beta Was this translation helpful? Give feedback.
-
Yet it's pragmatically what works best for many projects, not just Eclipse Platform. So while the overall workflow might be questionable to you, it's still not deprecated in the absence of a more comfortable alternative to Signing the artifacts in the p2 repo is a way to say that as a provider of the p2 repo, I do trust the content I ship in this p2 repo; reusing signer info doesn't provide that at all; copying the signature from a 3rd party signer doesn't imply it's trusted by some other provider. |
Beta Was this translation helpful? Give feedback.
-
By the way I think we can better serve users by enhancing the documentation here: https://tycho.eclipseprojects.io/doc/master/tycho-gpg-plugin/plugin-info.html How to Use, Why it is good and so on ... |
Beta Was this translation helpful? Give feedback.
The fact that the archived repo is missing PGP signatures is actually an issue in Tycho. You may want to open an issue for it so this can be improved in Tycho directly. Thinking further about it, the pgp sign mojo could be built-in the default lifecycle for
eclipse-repository
-hooked between assemble and archive- and be a no-op as long as the signing key is not set or empty (with a warningNo PGP signing key configured, skipped
).In the meantime, yes, I think this workaround a good-ish way to do it ("whatever works").