Git Web server for all SGEES Linux users is running at https://git.geo.vuw.ac.nz
Web interface is very similar to GitHub so you might find it convenient for your school collaborative or private projects (code, documents, theses). Free volume size for repositories is about 1 Tb - fair enough for various projects but definitely not suitable for large data sets.
Access#
Use your Linux account credentials to log in. For security reasons all Git accounts are locked by default. If you can’t login, please ask system administrator to unlock your account.
Protocols supported#
Two protocols: https and ssh (“SSH Keys”) are supported. NB: SSH protocol is open for local network only. When out of campus either switch to HTTPS or start VPN.
Import Public SSH Key#
a) Copy your local public SSH key stored in file ~/.ssh/id_rsa.pub
to clipboard
- In Windows this file could be found at
C:\Users\<YOUR_USER>\.ssh\id_rsa.pub
(this is a text file containing a single line which looks like ‘ssh-rsa AAAAB3NzaC1yc2EAAAADAQABA…LONG_LINE_OF_RANDOM_CHARACTERS…..VQ== user@example.com ’)
a.1) If there is no such file, then you need to generate one. Run ssh-keygen and press Enter several times for default options confirmation.
b) Go to import page at
https://git.geo.vuw.ac.nz/user/settings/keys , select “Manage SSH Keys” section, and click on “Add Key” button.
c) Paste the key and assign some meaningful name for it (like “My home laptop”)
d) Update protocol for existing local clones
In the local copy of repository change origin address (assume the repository name is “MYREPO” and your SGEES Linux login is “snowjon”)
cd /path/to/MYREPO
git remote set-url origin git@git.geo.vuw.ac.nz:snowjon/MYREPO.git
e) Repeat a–d for all other computers from which you might need access to git server
Paswordless access via HTTPS#
If you find it annoying to type your credentials each time when pull/push changes, there are several ways to do this.
a) Fast and insecure (generally not recommended) - use GIT credentials store
git config --global credential.helper store
git pull
Then your credentials will be stored in ~/.git-credentials as plain text
b) A more secure way - use GIT credential cache
git config credential.helper cache TIMEOUT
git pull
This case your login and password will be stored in memory for TIMEOUT time. This might be useful if you do frequent commits and set it e.g. as
git config credential.helper cache 86400
then you’ll not need to type login/password for the next 24 hours
c) Good balance between security and usability - use API tokens (also works with github and gitlab). This case you’ll never expose your password and can track access to repository.
Navigate to https://git.geo.vuw.ac.nz/user/settings/applications ,
Generate a token, copy it and store somewhere, as it will be shown only once
Now use pair of your login and token for clone of repository in a form like:
git clone https://USER:TOKEN@git.geo.vuw.ac.nz/USER/REPO.git
e.g.:
git clone https://beliaeal:36b4f14262bc035bc8023309f443125512007711@git.geo.vuw.ac.nz/beliaeal/seisan-11.git
Or change origin URL for existing repo with git config:
git remote set-url origin https://USER:TOKEN@git.geo.vuw.ac.nz/USER/REPO.git
e.g.:
git remote set-url origin https://beliaeal:36b4f14262bc035bc8023309f443125512007711@git.geo.vuw.ac.nz/beliaeal/seisan-11.git
Known Issues#
Gitea wiki engine uses a different naming convention (it conforms to GitHub standards), so if your old GOGS repository had a Wiki, you will have to clone wiki repo and rename all .md files with spaces in them either manually or using bash script to automate this.
As wiki pages are stored beside the main repository, wiki repository name will be MYREPO.wiki.git for MYREPO main repository
Here is step-by-step procedure:
git clone https://git.geo.vuw.ac.nz/USERNAME/MYREPO.wiki.git
cd MYREPO.wiki
rename 's/\ /\-/g' *.md
git add .
git commit -m "wiki names fixed"
git push