# NethServer 7 kickstart

## Prerequisites

Install NethServer 7. Refer to [Administrator manual](

## Developer environment

If you want to create a developer environment, first install mock configuration:


# yum install nethserver-mock


Create a normal user, member of the ``mock`` group:

useradd filippo
usermod -a -G mock filippo
passwd filippo

## GitHub-based workflow

[Fork a repository]( from [NethServer on GitHub]( For instance, ``nethserver-directory``.

After a logout and login as a normal user, clone locally your freshly forked repository: ``` git config –global credential.helper cache git clone ```

Enter the ``nethserver-directory`` dir, review the specfile looking for common issues and try to build the RPM.

``` $ cd nethserver-directory $ make-rpms nethserver-directory.spec ```

If everything is OK, you obtain two (or more) RPMs in the current directory:

``` $ ls -1 *.rpm nethserver-directory-2.2.0-1.1.ga90636c.ns7.noarch.rpm nethserver-directory-2.2.0-1.1.ga90636c.ns7.src.rpm ```

Switch to the root account and try to install the “noarch” RPM.

``` # yum localinstall ~davidep/nethserver-directory/nethserver-directory-2.2.0-1.1.ga90636c.ns7.noarch.rpm ```

## File a bug

As usual, if an error occurs during the RPM build or installation, check if the problem has been reported:

* See if a similar problem is listed on [v7 milestone]( or a [Pull Request]( has been opened

* Search the [development]( and [bug]( categories. We use the tag ``v7``.

* Ask for help on community, opening a new topic [on development category]( and adding the tag ``v7``

If you are sure the problem has never been found, file a new issue on

* Build errors are usually written to ``build.log`` file, in your current working directory. Search for relevant error messages inside ``build.log``. * Installation/Dependency errors are written to standard output

``` [TODO add example] ```

## Fix the bug

If you found the solution for a bug, share it! First of all, check if the git repository has a ``v7`` pacakge:

``` $ cd nethserver-directory $ git branch * master ```

If the ``v7`` branch has not been created yet, simply ignore the next step. Otherwise checkout it:

``` $ git branch * master


$ git checkout v7 ```

Then you're ready to write down the bug solution. Commit, push to your fork repository then [create a pull request]( for the ``v7`` branch (not master). Remeber to add a reference to the issue in the pull request description. For instance

``` The bug was caused by this and that

Refs NethServer/dev#5000 ```

## Common issues

When editing the ``.spec`` file

1. [Remove ``AutoReq: no``]( 2. [Claim ownership of ``<package>-update`` event]( 3. [Claim ownership of e-smith databases]( 4. [Use %{buildroot} macro in .spec file]( 5. [Use %{genfilelist} macro in .spec file](

When running ``make-rpms``, ``mock`` complains of ``localtime`` and prints the following line:

``` IOError: [Errno 21] Is a directory: '/etc/localtime' ```

To fix this issue, run:

rm -f /etc/localtime
ln -sf /usr/share/zoneinfo/Europe/Rome /etc/localtime
  • developer/nethserver_7_kickstart.txt
  • Last modified: 2017/02/07 10:13
  • by Davide Principi