Genesis - Chapter 7
In the instructions on the ark's design in Chapter 6, God told Noah to include one door in the side. God's judgement was coming and there was only one door through which safety could come. Noah and his family put their trust in God and, having built the ark, entered through that door. Once they were inside the Lord shut the door.
verse 16 - Then the Lord shut him in.
This is a strange thing to happen - after all Noah could easily have shut the door himself. But God is setting up a lesson for us. Once the door was closed it was the time for judgement. Those who had passed through the doors were already safe. Those who had not done so had now lost their chance. God had closed the door and no more could enter.
And the link to Jesus is in John Chapter 10: verse 9
Jesus says "I am the door; whoever enters through me will be saved."