7. Contribute

You may be interrested in contribute to MySecureShell project. We’re going to see here how you can do this :-)

7.1. Which kind of contribution are accepted?

Any kind of contribution is welcome in fact :-).

  • If it’s a bug or feature related, do not hesitate to use GitHub issues to inform us.
  • You created a patch for MySecureShell? Please use GitHub Pull Request to provide it.
  • You made a plugin for a third party application? Please inform us! And if you want we host it, do not hesitate to inform us.
  • The documentation is not good enough and you want to enhance it? Please make the changes from the sources by using a Pull Request
  • The documentation is not translated into your language? You can have a look to Transifex website and we will integrate it.
  • We did not make the package for your favorite distribution? Create your own and inform us how to install it, we will add it to the documentation!

As you can see, we’re open to any kind of contribution and hope you’ll enjoy contributing.

7.2. What is the easiest solution to contribute code or doc?

We are providing Docker and Vagrant files that will install everything you need to have (packages, sources, dependancies, documentation sources and so on…) to help you to contribute.

7.2.1. Docker

With Docker, here is the content file for development:

FROM debian:unstable
MAINTAINER Pierre Mavro <deimos@deimos.fr>

##################
# User Quick Try #
##################

RUN apt-get update
RUN DEBIAN_FRONTEND=noninteractive apt-get -y -o Dpkg::Options::="--force-confdef" \
 -o Dpkg::Options::="--force-confold" install whois procps openssh-server
RUN mkdir /var/run/sshd
RUN echo 'root:root' | chpasswd

#######
# DEV #
#######

RUN apt-get update
RUN apt-get -y install git
RUN git clone https://github.com/mysecureshell/mysecureshell.git
RUN apt-get -y install libacl1-dev libgnutls28-dev gcc make
RUN apt-get -y install build-essential fakeroot lintian devscripts debhelper ubuntu-dev-tools \
 cowbuilder autotools-dev
RUN apt-get -y install sphinx-doc sphinx-common python3-sphinx libjs-sphinxdoc \
 python-pip texlive-latex-base texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended
RUN apt-get clean
RUN pip install sphinx_rtd_theme

# Start SSHd
EXPOSE 22
CMD ["/usr/sbin/sshd", "-D"]

To install this container, simply build docker with the Dockerfile:

$ docker build -t mysecureshelldev \
https://raw.githubusercontent.com/mysecureshell/mysecureshell/master/deployment-tools/docker/dev/Dockerfile

Now you can run one:

$ docker run -d -p 22222:22 mysecureshelldev

If you need more explaination on how to use it, please look at the Quick Try section.

7.2.2. Vagrant

With Vagrant and the Vagrantfile:

# -*- mode: ruby -*-
# vi: set ft=ruby :
# MySecureShell Team <https://github.com/mysecureshell/mysecureshell>

# Vagrantfile API/syntax version. Don't touch unless you know what you're doing!
VAGRANTFILE_API_VERSION = "2" 

$install_mss = <<INSTALL
echo "deb http://mysecureshell.free.fr/repository/index.php/debian/7.1 testing main
deb-src http://mysecureshell.free.fr/repository/index.php/debian/7.1 testing main
" > /etc/apt/sources.list.d/mysecureshell.list
gpg --keyserver hkp://pool.sks-keyservers.net --recv-keys E328F22B
gpg --export E328F22B | apt-key add -
apt-get update
apt-get -y install mysecureshell
pass=$(mkpasswd -m sha-512 -s mssuser)
useradd -m -s /usr/bin/mysecureshell -p $pass mssuser
chmod 4755 /usr/bin/mysecureshell
INSTALL

$install_mss_dev = <<INSTALL
apt-get update
#install git
apt-get -y install git
#get the sources
if [ -f /vagrant/id_rsa ] ; then
    git clone git@github.com:mysecureshell/mysecureshell.git
else
    git clone https://github.com/mysecureshell/mysecureshell.git
fi
chown -Rf vagrant. mysecureshell
#install C dependencies
apt-get -y install libacl1-dev libgnutls-dev gcc make
#install packaging dependencies
apt-get -i install build-essential fakeroot lintian devscripts debhelper ubuntu-dev-tools cowbuilder
#install Sphinxdoc dependencies
apt-get -y install sphinx-doc sphinx-common python3-sphinx libjs-sphinxdoc python-pip \
texlive-latex-base texlive-latex-recommended texlive-latex-extra texlive-fonts-recommended
#install sphinxdoc theme
pip install sphinx_rtd_theme
INSTALL

Vagrant.configure(VAGRANTFILE_API_VERSION) do |config|
  config.vm.box = "deimosfr/debian-wheezy"
  config.vm.network "forwarded_port", guest: 22, host: 22222
  config.vm.network "private_network", ip: "192.168.33.10"
  config.vm.network "public_network"
  config.vm.provider "virtualbox" do |v|
        v.memory = 768
        v.cpus = 2
  end
  config.vm.provision "shell", inline: $install_mss
  # Uncomment if you want to install all dev dependancies (to contribute for example)
  #config.vm.provision "shell", inline: $install_mss_dev
end

you just need to uncomment this line to install all development dependencies:

#config.vm.provision "shell", inline: $install_mss_dev

Then launch it:

$ vagrant up

If you need more explaination on how to use it, please look at the Quick Try section.

7.3. How can I contribute to the documentation?

The simplest solution is to look at the previous section to create a development environment with all the prequesites to build the documentation.

All the documentation is based in the doc folder. The documentation has been made with Sphinx Doc, which is easy to use.

When you’ve got the development environment and made modifications in the documentation, you can try to generate a new one with this command inside the doc folder:

$ make html
sphinx-build -b html -d build/doctrees   source build/html
Running Sphinx v1.2.2
loading pickled environment... done
loading intersphinx inventory from http://docs.python.org/objects.inv...
building [html]: targets for 1 source files that are out of date
updating environment: 0 added, 1 changed, 0 removed
reading sources... [100%] contribute
looking for now-outdated files... 77 found
pickling environment... done
checking consistency... done
preparing documents... done
writing output... [100%] usages_user
writing additional files... genindex search
copying images... [100%] images/logo_ubuntu.png
copying static files... done
copying extra files... done
dumping search index... done
dumping object inventory... done
build succeeded, 1 warning.

Build finished. The HTML pages are in build/html.

This will generate an html documentation available in the doc/build/html folder. Once done, you can create a pull request for merging your modifications.

7.4. Share your MySecureShell usage and knowledge

If you like MySecureShell, do not hesitate to make blog posts, social sharing (Twitter, Google+, Facebook…) or participate with us to help users on GitHub issues.

Note

MySecureShell is available on Twitter with @MySecureShell username.

You can also help us on testing futures releases by participating to beta tests.