In a large saucepan, heat the canola oil. Add the ginger, garlic, curry leaves, chopped chiles, turmeric, 1 1/2 teaspoons of black pepper and 1/2 cup of the pearl onions. Season with salt and cook over moderate heat, stirring occasionally, until the onions are softened, about 8 minutes. Add the potato cubes, diced carrots, green beans, vegetable stock and the remaining 1/2 cup of pearl onions and bring to a boil. Add the coconut milk and simmer, partially covered, until the vegetables are tender and the coconut milk is slightly reduced, about 30 minutes. Season with salt and black pepper. Discard the bay leaves, if using, and serve.