My FeedDiscussionsHeadless CMS
New
Sign in
Log inSign up
Learn more about Hashnode Headless CMSHashnode Headless CMS
Collaborate seamlessly with Hashnode Headless CMS for Enterprise.
Upgrade ✨Learn more

Variables not working

Emil Moe's photo
Emil Moe
·Mar 30, 2020

I have set up some variables for my CI script at gitlab.com<group>/<project>/-/settings/ci_cd

Screenshot 2020-03-30 at 12.32.42.png


And I am trying to use them in .gitlab-ci-yml but it is as they are not parsed? If I put the content from the variables directly into the script, it works, but it fails when I refer them:

 $ npm-cli-login -u ${WEBIX_USER} -p ${WEBIX_PASSWORD} -e ${WEBIX_EMAIL} -r http://npm.webix.com -s @xbs
 /usr/lib/node_modules/npm-cli-login/lib/index.js:11
             throw new Error(err);
             ^

I read somewhere that it is intended that the variable name is displayed, but it doesn't change the fact that the login fails – and only when I refer variables, not when I hardcode the values.