I’m struggling a bit to deploy app to a dedicated VM. App build stage is OK, it passes, but the problem that I am facing is when I try to deploy app to the dedicated VM it gives the following error:
ln: failed to create symbolic link ‘/sys/fs/cgroup/systemd/name=systemd’: Operation not permitted
Finding any information on internet it points to the docker storage on the dedicated VM. Currently I am using overlay2 and not sure if this really causing it or not.
Also, I installed and configured runner which is locked to my specific project that I am trying to deploy. From gitlab I see that runner is running, seems all ok with this to me.
So not sure what am I missing or did I correctly setup dedicated VM. Please be aware that I am kind of new to this so if you need additional information to troubleshoot this please let me know.
Thanks in advance.
So the user on dedicated VM is created and added to the wheel group. Also private key is configured, I put it in the gitlab.com->Settings->CI/CD variables. Not sure if host key verification is caused by not creating ln or is it really permissions? Because connecting with the same private key from other machines works fine. But again user is in the wheel group.
Oh, so that error looks quite different. It seems that the Host key verification failed. is the important bit here.
Assuming that the DEPLOY_SERVER_IP is correct, I’d guess that the private key isn’t right for that user on that server.
If I were you, I’d start by running that scp command, exactly as it is in the log, from the command line. If the scp doesn’t work, then you know that something is up with the key.
If it does work, I’d check what rights user, and user is definitely in the right groups, I’d try running the deploy script on the server, as that user, to see where you get an error.