Having a rope swing/rotate along the x axis

I’m Having trouble making some ropes swing. It’s a 2d side scroller and I have a shape for the rope, i just flattened a cylinder, let me know if there is a better way to make a rope, but how do i make it so when the level starts, the rope just swings forever.