If you're on an iPhone, go to Settings / Notifications, and scroll down to the bottom of the screen to enable government alerts.
I've never knowingly signed up for them, but who knows what's going on when my wife does all the talking for phone purchases.
The alerts are based on your current location: for example, yesterday my wife got one in Shilin, but in Danshui I didn't. We both got alerts in Danshui the previous morning.
I asked my students about this when we all got alerts for the military drill a week back, and they laughed at the one girl with a Samsung phone who hadn't received it.