On Discourse the share post icon is a link (as in links-in-a-chain) icon. This also works well, but I think nowadays the nodes icon at the top here is most recognized.
It used to be the link icon, but that replaced the link icon where the share icon wouldn’t make sense (like on the formatting bar button for adding a link).
I just tested the below and it seems to work as intended:
hmm… I guess I wouldn’t worry that much about an icons “etymology” but rather if it’s commonly used in that context. And this seems pretty much the case here, e.g. here’s a view from twitter:
Well, agree to disagree, I find the share icon a better representation of the action than a link icon, but that’s just me. Also, if you’re on mobile, this action will actually open the OS share UI, and I’m pretty sure that the link approach is only used because we don’t have a good support for the Web Share API on desktop just yet.
If I understand the comment by @Jagster correctly, he is not arguing against the use of share-alt for the external-link-plus-SM-share popup on desktop / OS share UI on mobile, but rather he saying that since it is a share functionality, using the external link icon wouldn’t cover the functionality entirely.