##// END OF EJS Templates
gists: use colander schema to validate input data....
gists: use colander schema to validate input data. - brings consistent validation acros API and web - use nicer and stricter schemas to validate data - fixes #4118

File last commit:

r515:46042b47 default
r523:878882bd default
Show More
dev-setup.rst
157 lines | 3.9 KiB | text/x-rst | RstLexer
docs: more comprehensive contributor docs #4039
r303 .. _dev-setup:
project: added all source files and assets
r1
===================
Development setup
===================
RhodeCode Enterprise runs inside a Nix managed environment. This ensures build
environment dependencies are correctly declared and installed during setup.
It also enables atomic upgrades, rollbacks, and multiple instances of RhodeCode
docs: improve contribution docs on how to run tests.
r272 Enterprise running with isolation.
project: added all source files and assets
r1
docs: updates to contributor documentation #4039
r271 To set up RhodeCode Enterprise inside the Nix environment, use the following steps:
project: added all source files and assets
r1
Setup Nix Package Manager
-------------------------
docs: updates to contributor documentation #4039
r271 To install the Nix Package Manager, please run::
project: added all source files and assets
r1
$ curl https://nixos.org/nix/install | sh
docs: updates to contributor documentation #4039
r271 or go to https://nixos.org/nix/ and follow the installation instructions.
Once this is correctly set up on your system, you should be able to use the
project: added all source files and assets
r1 following commands:
* `nix-env`
* `nix-shell`
.. tip::
Update your channels frequently by running ``nix-channel --upgrade``.
docs: updates to contributor documentation #4039
r271 Switch nix to the latest STABLE channel
---------------------------------------
project: added all source files and assets
r1
run::
nix-channel --add https://nixos.org/channels/nixos-16.03 nixpkgs
Followed by::
nix-channel --update
Clone the required repositories
-------------------------------
docs: updates to contributor documentation #4039
r271 After Nix is set up, clone the RhodeCode Enterprise Community Edition and
project: added all source files and assets
r1 RhodeCode VCSServer repositories into the same directory.
To do this, use the following example::
mkdir rhodecode-develop && cd rhodecode-develop
hg clone https://code.rhodecode.com/rhodecode-enterprise-ce
hg clone https://code.rhodecode.com/rhodecode-vcsserver
.. note::
docs: improve contribution docs on how to run tests.
r272 If you cannot clone the repository, please request read permissions
via support@rhodecode.com
project: added all source files and assets
r1
Enter the Development Shell
---------------------------
docs: updates to contributor documentation #4039
r271 The final step is to start the development shell. To do this, run the
project: added all source files and assets
r1 following command from inside the cloned repository::
cd ~/rhodecode-enterprise-ce
docs: updates to contributor documentation #4039
r271 nix-shell
project: added all source files and assets
r1
.. note::
On the first run, this will take a while to download and optionally compile
docs: improve contribution docs on how to run tests.
r272 a few things. The following runs will be faster. The development shell works
docs: update dev setup instructions
r489 fine on both MacOS and Linux platforms.
project: added all source files and assets
r1
Creating a Development Configuration
------------------------------------
To create a development environment for RhodeCode Enterprise,
use the following steps:
1. Create a copy of `~/rhodecode-enterprise-ce/configs/development.ini`
2. Adjust the configuration settings to your needs
docs: updating vcsserver commands and development.ini defaults
r491 .. note::
project: added all source files and assets
r1
docs: updating vcsserver commands and development.ini defaults
r491 It is recommended to use the name `dev.ini`.
project: added all source files and assets
r1
Setup the Development Database
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
docs: updates to contributor documentation #4039
r271 To create a development database, use the following example. This is a one
project: added all source files and assets
r1 time operation::
paster setup-rhodecode dev.ini \
--user=admin --password=secret \
--email=admin@example.com \
--repos=~/my_dev_repos
docs: adding frontend compile instructions to dev setup
r490 Compile CSS and JavaScript
^^^^^^^^^^^^^^^^^^^^^^^^^^
To use the application's frontend, you will need to compile the CSS and
JavaScript with Grunt. This is easily done from within the nix-shell using the
following command::
make web-build
You will need to recompile following any changes made to the CSS or JavaScript
files.
project: added all source files and assets
r1 Start the Development Server
^^^^^^^^^^^^^^^^^^^^^^^^^^^^
docs: update dev setup instructions
r489 From the rhodecode-vcsserver directory, start the development server in another
nix-shell, using the following command::
project: added all source files and assets
r1
docs: updating vccserver ini file name in setup instructions
r515 pserve configs/development.ini http_port=9900
project: added all source files and assets
r1
docs: update dev setup instructions
r489 In the adjacent nix-shell which you created for your development server, you may
now start CE with the following command::
project: added all source files and assets
r1
docs: updating vcsserver commands and development.ini defaults
r491
docs: update dev setup instructions
r489 rcserver dev.ini
project: added all source files and assets
r1
docs: updating vcsserver commands and development.ini defaults
r491 .. note::
To automatically refresh - and recompile the frontend assets - when changes
are made in the source code, you can use the option `--reload`.
project: added all source files and assets
r1
Run the Environment Tests
^^^^^^^^^^^^^^^^^^^^^^^^^
docs: updates to contributor documentation #4039
r271 Please make sure that the tests are passing to verify that your environment is
docs: improve contribution docs on how to run tests.
r272 set up correctly. RhodeCode uses py.test to run tests.
docs: update dev setup instructions
r489 While your instance is running, start a new nix-shell and simply run
``make test`` to run the basic test suite.
Need Help?
^^^^^^^^^^
Join us on Slack via https://rhodecode.com/join or post questions in our
Community Portal at https://community.rhodecode.com