A man has been jailed for murder after delivering a deadly punch outside a South Wales pub.