Eclipse Che Get SSH Workspace Public Key

If you are working with a source code versioning system such as github.com or Gitlab you may need to create a private and public keypair in order to clone your repositories within your workspaces.

To achieve this you may use the following command substituting the [CONTAINER ID] for your Eclipse Che workspace instance ID.

First within the Terminal pane of your workspace generate a keypair if one doesn’t already exists using the ‘ssh-keygen’ command.

Once the keypair is created run this command from your docker host.

`$ docker exec [CONTAINER ID] cat /home/user/.ssh/id_rsa.pub`

GitLab Disable Gravatar

You can disable Gravatar in GitLab using the following two methods.

Open the configuration file and add

 

nano /var/opt/gitlab/gitlab-shell/config.yml

 

Add

gravatar.enabled: false

Edit your hosts file

nano /etc/hosts

Add line

127.0.0.1 gravatar.com

Save changes, reboot

 

GitLab 7.x HTTPS Configuration


nano /var/opt/gitlab/nginx/etc/gitlab-http.conf


BEFORE

 

server {

 

   listen *:80;

 

   server_name host.com;

 

   server_tokens off;     # don’t show the version number, a security best practice

 

   root /opt/gitlab/embedded/service/gitlab-rails/public;

 

 

 

 


AFTER

 

server {

 

  listen *:443 ssl;

 

  server_name host.com;

 

  server_tokens off;     # don’t show the version number, a security best practice

 

  root /opt/gitlab/embedded/service/gitlab-rails/public;

 

  ssl_certificate /var/opt/gitlab/nginx/ssl/server.crt;

 

  ssl_certificate_key /var/opt/gitlab/nginx/ssl/server.key;


Backup GitLab


bundle exec rake RAILS_ENV=production gitlab:backup:create

The backup will should be created and located here.

/home/git/gitlab/tmp/backups

 

something like

3407151110_gitlab_backup.tar

 Download this file and restore it to the another sever to ensure you have a good backup. A backup that hasn’t been tested is not a backup at all.

 To restore a backup

 bundle exec rake gitlab:backup:restore RAILS_ENV=production


 

 

References:

https://wiki.archlinux.org/index.php/gitlab

https://gitlab.com/gitlab-org/gitlab-ce/blob/master/doc/raketasks/backup_restore.md