This pull request improves the build and deployment process for the project, with a focus on ensuring that the tools directory (including the Discord bot) is correctly included in publish outputs and Docker images. It also enhances the workflow and build scripts to better handle multi-platform publishing and fallback scenarios.
Build and publish process improvements:
- Added explicit logic in
listenarr.api/Listenarr.Api.csprojto copy thetoolsdirectory from the repository root to all publish output locations, including fallback and nested publish folders. This ensures tools are always available after publishing, regardless of the environment. - Updated the Docker runtime image (
listenarr.api/Dockerfile.runtime) to copy thetoolsdirectory into the image, install Discord bot dependencies, and set up the working directory for the bot, making sure the bot and its dependencies are available at runtime.
Workflow configuration updates:
- Modified CI and canary GitHub Actions workflows to provide correct build arguments for the publish directory, improving compatibility with multi-platform builds and ensuring the right files are included in each image. [1] [2]
MSBuild and project file enhancements:
- Improved MSBuild targets in
Listenarr.Api.csprojto better handle frontend and tools copying, including multiple fallback locations for publish outputs to support various CI scenarios. Also fixed the path for including tools from outside the project directory. [1] [2] [3]
...
Automated canary build