Now.sh alias command not working

I have the following deploy step in my config.yml:

      - deploy:
          working_directory: web
          command: |
              URL=$(now -t ${NOW_TOKEN})
              now -t ${NOW_TOKEN} alias ${URL} basho.ai

The first of the two commands works, as I can confirm via logs in my now dashboard, but the second does not. What am I doing wrong? I know my env var is set correctly because the first command works, so I think maybe URL does not have the value I expect in the second command.

Here’s a link to the full repo: https://github.com/granmoe/basho

Just commenting to try to get this issue seen

Can’t you somehow output the variable to check if it is correct?
Also, what does “not work” mean exactly? Error message? Silent failure?

Sorry, I was pretty vague there. Silent failure is exactly what’s happening. Everything appears to work according to Circle CI, but I see ZERO logs in my now.sh dashboard, and I see a stale version of my app still deployed. I also opened an issue on github on the now cli repo: https://github.com/zeit/now-cli/issues/1015

I’m going to try what you suggest and see if I can log out the variables in those commands. Also, maybe Circle CI has a verbose option?

1 Like

Is there any way of debugging Circle CI or just grabbing the terminal output? I printed the env variable, and it’s correct. I tried adding the --debug option to my now commands, but I don’t see any output in my logs. I’ve seen some people write the output to a file and then move that file to $CIRCLE_ARTIFACTS, but I can’t find anything in the docs regarding how to set that env var up.