The phrase
"goal posts" refers to the vertical bars or poles that are used in some sports, like football or soccer, to mark the area where players can score points. The phrase is often used figuratively to describe when someone changes the rules or expectations in order to make it harder to achieve a goal or to criticize someone for doing so.
Full definition