The movie I remember is not from Hollywood, below are some of the scene references.
Theme of the story is people get trapped in certain places (with recurring food and water for their survival) and have no connection with the outside world and ultimately they die (because of ageing). Of all the people who get trapped, one particular person, who is about to die, recalls that he should have not entered into (that place where they are about to get trapped) and informs the same to the youngest of them. But the situations will be in such a way that it lures the people to get into it.
Some of the scenes I have in my mind are:
A family (mom, dad, daughter and a son) goes on a family vacation in a car. In their journey, they hear a blast very far away. This is when they get trapped. They finally realise they are trapped. They lose the asthma inhaler of the daughter, as the bottle shatters falling on the road. All they have is a gas station, where they have all the supplies they need until they die of ageing.
When the dad is about to die, he recalls and explains to his son that it is a curse like thing and you will be lured in to get trapped. And the father dies. Like the father said, there comes a police car. And the person who survived gets into the police car and here starts the loop again.