How to configure build status updates to Slack with links to artifacts in codemagic.yaml
Integrate Slack publishing into your Codemagic build pipeline to get notified when a build starts and receive build artifacts or logs when the build finishes.
Connecting your Slack workspace
To set up publishing to Slack, you first need to connect your Slack workspace in User settings > Integrations > Slack for personal apps and in Teams > Your_team > Team integrations > Slack for team apps.
After you have successfully authorized Codemagic and connected your workspace, you will be redirected back to Codemagic. You can disconnect your Slack workspace anytime by clicking Disconnect.
Configuring Slack publishing
The Slack channel for publishing is configured separately for each workflow in the
publishing section of
codemagic.yaml (refer here if you’re configuring app settings in the Flutter workflow editor).
@codemagicin the channel. If the private channel access is restricted by Slack admin rights, it will have to be changed manually, otherwise publishing to that channel will not be possible.
If the build finishes successfully, release notes (if passed), and the generated artifacts will be published to the specified channel. If the build fails, a link to the build logs is published. When you set
true, the channel will be notified when a build starts.
If you don’t want to receive a Slack notification on build success or failure, you can set
publishing: slack: channel: '#channel-name' notify_on_build_start: true # To receive a notification when a build starts notify: success: false # To not receive a notification when a build succeeds failure: false # To not receive a notification when a build fails
When you set up Slack publishing, Codemagic publishes the following artifacts:
apk, the archive with Flutter web build directory, Linux application bundle files, Windows MSIX packages