Scripture speaks of how God opens and closes doors for His children to accomplish His work. Revelation 3:8, Colossians 4:3-4, Acts 14:27 There is also a lot in Scripture about God making paths which is a similar analogy of God's guidance and provision. However, I do not believe we are to use it as an excuse to give up because of obstacles. A closed door is an ending. An obstacle is a hurdle you can get around or go over on your way to the goal. Hurdles strengthen us and prepare us for the job at the end.
I like the metaphor of the Christian life being like running a race in Scripture because a race takes and demands so much more from us than a walk...especially at the end.