Preheat the oven to 400°F (204°C). Slick a rimmed baking sheet with cooking spray. Season the pork with 3 teaspoons of the salt and the black pepper, making sure to cover the whole pork shoulder.
Place the onion and pineapple on the prepared baking sheet. Drizzle the onion and pineapple with 1 tablespoon of the oil and sprinkle them with 1/4 teaspoon of the salt.
Roast the onion and pineapple until tender, flipping them halfway through the cooking time, 15 to 16 minutes. Add the brown sugar and toss the roasted onion and pineapple to coat them. Roast the onion and pineapple until they start to caramelize, 3 to 4 minutes.
Drop the onion and pineapple into a blender or large food processor. Add the lime juice, lime zest, orange juice, orange zest, remaining 1 tablespoon of oil, broth, vinegar, garlic, chipotle peppers, adobo sauce, chili powder, cumin, coriander, oregano, onion powder, allspice, and remaining 1/4 teaspoon of salt. Blitz the ingredients until a smooth, thick sauce forms.
Place the pork in the slow cooker and cover with the pineapple sauce. Cook on low heat until the pork is fork tender, 7 to 8 hours. Move the pork to a large bowl, and remove the bone if you are cooking a bone-in pork shoulder. Remove any fatty pieces, then use forks or tongs to shred the pork.
Stir in 1/2 cup or more of the leftover sauce from the slow cooker, if desired.