Skip to content

Commit 98b9b34

Browse files
authored
Update installation.rst
1 parent a5b8dbc commit 98b9b34

File tree

1 file changed

+52
-11
lines changed

1 file changed

+52
-11
lines changed

docs/installation.rst

Lines changed: 52 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ This section describes how to get DRMAAtic up and running on your system.
55

66
**Prerequisites:**
77
- Linux environment
8-
- SLURM with DRMAA library (or Docker)
8+
- SLURM with DRMAA library (or the provided Docker setup)
99
- Python 3.8+ or Docker Engine
1010

1111
Using Docker (Recommended)
@@ -14,28 +14,69 @@ Using Docker (Recommended)
1414
git clone https://github.com/BioComputingUP/DRMAAtic.git
1515
cd DRMAAtic/docker
1616

17-
2. Launch the test environment:
17+
2. Deploy a test cluster (including a SLURM simulator, database, and DRMAAtic) using the provided docker compose file:
18+
19+
.. code-block:: bash
20+
1821
cd testing
19-
docker-compose up -d
22+
docker-compose up -d
23+
24+
This will start a local SLURM controller, a compute node, a MySQL database, and the DRMAAtic REST API service in containers, creating a self-contained test cluster environment.
25+
26+
3. OR deploy with an existing cluster:
27+
28+
* Edit configuration files (like ``slurm.conf``, database settings, etc.) in ``/deploy/deploy-example/`` to match your cluster.
29+
* Start the DRMAAtic container and connect it to your cluster’s SLURM and database:
30+
31+
.. code-block:: bash
2032
21-
3. OR deploy with an existing cluster using:
2233
cd ../deploy-example
2334
docker-compose up -d
2435
25-
Post-install, run migrations and create a superuser:
26-
docker exec -it drmaatic /opt/venv/bin/python3 manage.py migrate
27-
docker exec -it drmaatic /opt/venv/bin/python3 manage.py createsuperuser
36+
* After the container(s) are running, proceed to initial setup (database migrations and creating an admin user) as described below:
37+
38+
.. code-block:: bash
39+
40+
docker exec -it drmaatic /opt/venv/bin/python3 manage.py migrate
41+
docker exec -it drmaatic /opt/venv/bin/python3 manage.py createsuperuser
2842
2943
Manual Installation
3044
-------------------
31-
1. Clone and install dependencies:
45+
1. Clone the repository and install Python dependencies:
46+
47+
.. code-block:: bash
48+
3249
git clone https://github.com/BioComputingUP/DRMAAtic.git
3350
cd DRMAAtic
3451
pip install -r requirements.txt
3552
36-
2. Configure the database and run:
53+
Ensure you have SLURM installed on the host and its DRMAA library available (the drmaa Python package will interface with it).
54+
55+
2. Configure the database: By default DRMAAtic uses MySQL/MariaDB. Set up a database and update the Django settings (or ``.env`` files in ``server/settings/``) with the DB credentials. For example, create a MySQL database named drmaatic and update ``server/settings/.env`` accordingly.
56+
57+
3. Run database migrations to set up the schema:
58+
59+
.. code-block:: bash
60+
61+
python manage.py makemigrations
3762
python manage.py migrate
38-
python manage.py createsuperuser
63+
64+
This will create the necessary tables for tasks, users, etc. in the database.
65+
66+
4. Create a superuser account for the Django admin (to manage tasks, etc.):
67+
68+
.. code-block:: bash
69+
70+
python manage.py createsuperuser
71+
72+
Follow the prompts to set up an admin username and password
73+
74+
5. Start the DRMAAtic server:
75+
76+
.. code-block:: bash
3977
40-
3. Run the server:
4178
python manage.py runserver
79+
80+
By default, this will run the development server at ``http://127.0.0.1:8000/``. You should now have the DRMAAtic API available (though without a running SLURM, job submission will not function).
81+
82+
.. NOTE:: Accessing the Web API: Once running, the API endpoints can be accessed via ``http://<server>/api/...`` (if using the development server or appropriate host/port for Docker). You can also log into the Django admin UI at ``http://<server>/admin/`` using the superuser credentials, to configure tasks and view job records.

0 commit comments

Comments
 (0)