node.jsgitlabgitlab-ciadonis.js

Gitlab CI variables returns empty string?


It's been 2 days since one of my project' build starts failing on Gitlab CI. The main error was E_MISSING_APP_KEY and when I check another variable just by echoing $HOST and $PORT from my .gitlab-ci.yml config, like this

tests:
  script:
    - echo "${HOST} ${PORT}"
    - node -e "console.log(process.env.HOST, process.env.PORT)"
    - node_modules/.bin/nyc node ace test -t 0

I got nothing.

initial error

The build was failed because it can't read my environment variable that I set on its CI Settings.

my CI variable setting

Anyone experiencing same issue? & how to solve this?


Update:

I'm trying to create new project with only containing .gitlab-ci.yml file here and it's seems working just fine

result on new dummy project

But why the world it's still failing on my main project?

kee failing


Solution

  • The issue is solved by delete all of my variables I've had & set them back from the CI Setting. And the build pipeline is running without any errors. (except the actual testing is still failed, lol)

    enter image description here

    Honestly, I'm still wondering why this could happened? and hopefully no one will experiencing same kind of issue like me here..