Thinly slice the onions and place them in the bottom of a 6-quart or larger slow cooker.
Rinse the Boston butt and place it on top of the onions.
Sprinkle with spices.
Pour the whole can of pineapple over it. If using fresh pineapple, peel, core, and thin chop the pineapple and place over pork.
Add the apple cider vinegar.
Put the lid on the slow cooker and cook on low for 10-12 hours or until fork tender. Don't open until at least 8 hours and then check for tenderness.
Shred with two forks to make pulled pork and top with barbecue sauce if using.
For the Instant Pot: Follow steps 1-3 as written. Instead of using a slow cooker, put everything except the barbecue sauce in the Instant Pot and set on manual for 60 minutes. Let cook and let steam release naturally after cooking. Mix in the barbecue sauce after shredding.