For the mashed potatoes: In a Dutch oven or heavy-bottomed pot, add the potatoes, garlic, sea salt and 1 quart cold water. Bring to a boil, then reduce to a simmer and cook until the potatoes are tender, 20 to 25 minutes. Discard all but 1/2 cup water. Transfer the potatoes and garlic to a bowl. Add the cream and butter and use an immersion blender to create a mash; don't overblend. Season with kosher salt and pepper.
For the pierogies: Mix 1 cup of the prepared mashed potatoes with the ham, Gruyere, 2 tablespoons butter and the chives. (Reserve any remaining mashed potatoes for another use.)
Add the flour, egg, 1 tablespoon butter, sour cream, kosher salt and 1 cup cold water to a food processor. Mix the dough gently until it turns into a ball and let rest 1 hour or up to overnight in the refrigerator.
Remove the dough from the refrigerator and roll out the dough to 1/8-inch thick. Cut out 3-inch rounds. Brush the dough with a bit of water, then add 2 teaspoons potato-ham mixture. Fold the dough in half and seal the edges with a fork. Repeat with the remaining dough and filling.
Fill a high-sided saute pan with salted water and bring to a simmer. Add the pierogies and gently simmer the pierogies for 2 minutes, drain and dry. Add the remaining 2 tablespoons butter plus the olive oil to a large cast-iron skillet and heat over medium-high heat. Once the butter has melted, add the pierogies and cook until golden on both sides, about 5 minutes total. Remove and drain on a paper towel-lined plate. Serve with sour cream on the side.