Preston Garvey and Radio Freedom can assign this randomly triggered quest, which is limited to settlements aligned with The Minutemen. Head to the designated settlement and speak to the marked settler for the details.
This quest involves building defenses in anticipation of a coming raid. It's focused on destroying the settlement's artillery cannon. Build turrets until you satisfy the quest's conditions.
Shortly after this (you might need to wait by sitting or sleeping one hour at a time), the invaders will arrive. Take out any enemies you find to help the turrets. You can also hang out near the artillery since that's your enemies' primary target. Note that some invaders might come from other factions, if they oppose The Minutemen. After you've saved the settlement, speak with the marked settler and then see Preston Garvey for your reward.