You are here
Hi, I'm new here to the forums and to TurnKey Linux. From what I've been reading, this is a great community! And TurnKey Linux is awesome! But anyway...
I'm running an OpenVZ container with GitLab on Proxmox version 2.2. I downloaded the template from Proxmox, and I've downloaded it from here as an OpenVZ container. I've followed the steps to enable the OpenVZ console, so that's not a problem. I can get to the GitLab login page, and login with username/email - 'admin@example.com' and password - 'turnkey'. I tried creating a new project, but I'm asked by GitLab to create an SSH key (which the appliance does for us.) So I went to 'My profile', then 'Add public key.' I pasted in the key I found in '/home/git/gitlab.pub' and removed the line breaks. The key is added successfully (or so it says). I am then instructed by GitLab to 'push the repository.' So I go to the IP that GitLab is given followed by ':12320' for the web shell. At this point, (GitLab has already created the repo) I cd into '/home/git/repositories/example.git'. I try a 'git status', gives some error, so I type 'git init' to initialize an 'empty branch'. I then type, 'git remote add origin git@git.example.com:example.git'. That goes okay. I type 'git push -u origin master' and it prompts for a password. I've put in every password I know of and it does not work. I typed 'ssh -vvv git@git.example.com' and it gives me some output that looks like it's looking for the key in '/root/.ssh/ida_rsa' and doesn't find it there. Any ideas?
In advance, I apologize for this obscenely large post. :)
Have you run the init/firstboot scripts?
All OVZ containers need to be initialised prior to first use:
Hopefully that will solve your issues!?
I have been using the GitLab appliance and don't recall having to go though the steps you are talking about (although I did have to add my key to be able to push to the server from my laptop). I have used it only externally though - as in how you would use GitHub - not from within the GitLab appliance (as it sound like you are).
Doing 'turnkey-init' seems to
Doing 'turnkey-init' seems to have broken it. The GitLab service doesn't exist anymore and now nginx gives a '502 Bad Gateway' message. I should have mentioned that I tried another way as well. I used tkliso2ovz to convert the GitLab ISO into an OpenVZ Container and that seems to run 'turnkey-init' on first boot. All of the ways I've tried, I get the original result. Adding the SSH key and then I am unable to push a repo because it doesn't like any password I give it. I should also add at this point that if I try 'ssh-add' it says 'Could not open a connection to your authentication agent.' And when I try 'pgrep ssh' nothing appears so I'm assuming there isn't an SSH process running. Also, I add the SSH key through the GitLab web interface and it takes it just fine. I just can't push a repo which then complains the password isn't right. Doing 'ssh -vvv git@git.example.com:example.git' complains that it can't connect either.
As strange as it may sound...
I think that is a good sign. Let me guess, you are running it with less than 1GB RAM? The fact that you get a 502 and the service isn't running is because it stalls due to not enough RAM. Or at least that's what I've experienced.
I am running the TKL OVZ build direct from within the PVE UI (which is the build that is hosted on SourceForge). When I was mucking around trying to update it I launched about 6 instances of it and it just worked OOTB (when given 1GB RAM and after running 'turnkey-init'). Although in fairness I never tested pushing to any of the 6 test instances I created (just the first that I used). I do recall having to manually start shh via the host console on very first boot.
When I get a chance tonight I'll try a fresh instance ang see how it goes...
It's more of a "me" thing...
Well, I was unaware that there were 2 'create project' buttons. The one that works for me is in the 'admin' section. I didn't realize I had to add a key if you use the other one. As far as the SSH thing, that would be ignorance on my part. I generated the key IN the appliance and tried to use it IN the appliance. So that would explain why it wouldn't work correctly. I'm pretty new to version control and SSH. Anyway, Thanks Jeremy for all your help. I really appreciate it.
No worries!
Glad to hear that you got it sorted and that you are all go! :)
As a general rule best to start a new thread
Anyway, in response to your question...:
After a bit of troubleshooting I can confirm that there is a pretty serious issue with v14.0 GitLab app. Not only does the inithook not work to setup the admin account; it seems that doing it via the commandline doesn't work either...
So sorry but at this point GitLab is broken with no easy fix :(
I have lodged a bug report: https://github.com/turnkeylinux/tracker/issues/465
We have a fix!
Note: There seems to be some minimum password complexity requirements but I'm not 100% sure what they are. A 6 character password using only lowercase was accepted but I couldn't login. I didn't exhaustively test it but it appears that a password with at least 8 characters including a number will work.
It will take a while for the script to complete but you should then be able to log in using your email and the new password. If you get a 504 error when you try to log in it means that the GitLab process hasn't finished starting so just wait and try again (when testing I just closed the browser window, reopened it and it was working).
Are you running in a container?
In the meantime you'll need to use one of the other build types (in a VM rather than a container). FWIW the appliance (in other builds e.g. ISO, OVA, etc) has been fixed and re-released (so should work OOTB now).
Great! :)
Add new comment