I’m using GitHub Actions as a CI system for a project I’m working on, and have recently added a .snk file to the project and want to strong-name the assembly. The following items have been added to the .csproj file:
<PropertyGroup>
<SignAssembly>true</SignAssembly>
<AssemblyOriginatorKeyFile>keyfile.snk</AssemblyOriginatorKeyFile>
</PropertyGroup>
The file exists in the same directory as the .csproj file. It builds perfectly fine locally (I’ve tested OSX and Windows), and properly yields a strong-named assembly. When I attempt to build the project in GitHub Actions, however, I receive the following error:
CSC : error CS7027: Error signing output with public key from file 'keyfile.snk' -- File not found.
The file is present in the repository, in the proper location. While the GitHub Actions runner is running Ubuntu, I can’t imagine why that would cause an issue. What am I missing?