Heat a large pot over medium-low heat and add the coconut oil. Stir in the onion and cook, stirring often, until it begins to caramelize and get golden brown, about 15 to 20 minutes. Stir in the garlic, ginger, salt and pepper. Cook for about 5 to 6 minutes. Stir in the sweet potato cubes. Cook for another 5 minutes, stirring occasionally, until the sweet potatoes start soften and get a little golden too. Pour in the vegetable stock and bring the mixture to a boil. Reduce it to a simmer, cover the pot and cook for 15 to 20 minutes, just until the sweet potatoes soften.