diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml
index e1389296c6270f8673c62f3ac1075a524a0b7198..65b8ecc72fc9927af1f6cbd80c74498526c9680b 100644
--- a/.gitlab-ci.yml
+++ b/.gitlab-ci.yml
@@ -11,6 +11,9 @@ include:
 variables:
   SONAR_PROJECT_KEY: config
   SONAR_TOKEN: 11922a8e774494f51e1d2f0e695949e4073e7df8
+  NPM_USERNAME: git
+  NPM_PASSWORD: git
+  NPM_EMAIL: git@git.de
 
 cache:
   paths:
@@ -42,6 +45,15 @@ test:
 publish to local npm:
   stage: publish
   before_script:
-    - echo '//it-devops-01:4873/:_authToken="ZMh1NzlklUTNNvt573Imgw=="' > .npmrc
+    - apt-get install expect
+    - |
+        /usr/bin/expect <<EOD
+        spawn npm adduser --registry https://it-devops-01:4873
+        expect {
+            "Username:" {send "$NPM_USERNAME\r"; exp_continue}
+            "Password:" {send "$NPM_PASSWORD\r"; exp_continue}
+            "Email: (this IS public)" {send "$NPM_EMAIL\r"; exp_continue}
+        }
+        EOD
   script:
     - npm publish --registry https://it-devops-01:4873
\ No newline at end of file