bonfire
bonfire copied to clipboard
Bonfire should check the validity of GITHUB_TOKEN
Recently my token expired. Instead of an error notifying me that I needed a new token, Bonfire would error out attempting to deploy a frontend (curiosity)
2024-04-25 15:57:13 [ WARNING] [ MainThread] http response 404 for url https://raw.githubusercontent.com/RedHatInsights/curiosity-frontend/e4e2f7ea7da3507f18e796e813dab8860ca65593/deploy/frontend.yaml, checking for template in current working dir...
2024-04-25 15:57:13 [ ERROR] [ MainThread] failed to fetch template file for curiosity-frontend
2024-04-25 15:57:13 [ ERROR] [ MainThread] hit fatal error: [Errno 2] No such file or directory: '/home/awood/devel/rhsm-subscriptions/deploy/frontend.yaml'
2024-04-25 15:57:13 [ INFO] [ MainThread] deploy failed: [Errno 2] No such file or directory: '/home/awood/devel/rhsm-subscriptions/deploy/frontend.yaml'
ERROR: deploy failed: [Errno 2] No such file or directory: '/home/awood/devel/rhsm-subscriptions/deploy/frontend.yaml'
I spent awhile trying to figure out why --frontends false
wasn't working before a sharp-eyed colleague noticed the warning and mentioned the token which I realized had expired.
A check of the token's validity right at the beginning would be nice but if that's not possible, than even just an addition to the warning message like "Has your GITHUB_TOKEN expired or been left unset in .config/bonfire/env?" would be helpful.