From 553b27f57d724b0703515c6fec562945443f7ddb Mon Sep 17 00:00:00 2001
From: Nico Vermaas <vermaas@astron.nl>
Date: Fri, 29 Jan 2021 08:01:44 +0100
Subject: [PATCH] adding to documentation

---
 README.md                                     | 28 ++++++++++++++-----
 .../templates/taskdatabase/index.html         |  2 +-
 2 files changed, 22 insertions(+), 8 deletions(-)

diff --git a/README.md b/README.md
index d391815e..946e9ba8 100644
--- a/README.md
+++ b/README.md
@@ -21,13 +21,13 @@ REST API
 Confluence Page:
   * https://support.astron.nl/confluence/display/LDV/LOFAR+Data+Valorization+Home
 
-Workflow:
-This diagram roughly serves as the specs for adapting ATDB for LDV.
-  * https://support.astron.nl/confluence/display/LDV/WORKFLOW
+Specifications:
+These diagrams roughly serves as the specifications for adapting ATDB for LDV.
+  * workflow: https://support.astron.nl/confluence/display/LDV/WORKFLOW
+  * datamodel: https://dbdiagram.io/d/5ffc5fb180d742080a35d560
 
 ## Overview Diagrams (under construction)
 These diagrams are the core of the ATDB documentation.
-Currently they are still mostly the original ATDB diagrams. They will be adapted and kept in sync once the ATDB-LDV structure solifies a bit more.
 
 ### Datamodel:
   * https://drive.google.com/file/d/1v5hMBQS0jT8DQJwySVISfRa1zF4o0fCQ/view?usp=sharing  
@@ -68,12 +68,26 @@ This is done to not have a mandatory deploy for every minor commmit.
     > cd $DOCKER_COMPOSE_DIR
     > docker-compose -p atdb up -d
     
-### Database migrations
+### Database changes and migrations
 When the `models.py` is changed, then the database must be migrated.
-This is how to do that manually for a persistent database in a Docker container.
+This is the procedure for that.
+
+  on local dev:
+  
+    > python manage.py makemigrations --settings=atdb.settings.dev
+    > python manage.py migrate --settings=atdb.settings.dev
+    - add new migration file to git
+    - commit & push
+
+  on CI/CD page: https://git.astron.nl/astron-sdc/atdb-ldv/-/pipelines
+
+    - when automatic build is finished, push >> to deploy
+  
+  on sdc machine:
 
     > docker exec -it atdb-ldv python manage.py makemigrations --settings atdb.settings.docker_sdc
-    > docker exec -it atdb-ldv python manage.py migrate --settings atdb.settings.docker_sdc    
+    > docker exec -it atdb-ldv python manage.py migrate --settings atdb.settings.docker_sdc
+
     
 ## Postgres Database operations
 
diff --git a/atdb/taskdatabase/templates/taskdatabase/index.html b/atdb/taskdatabase/templates/taskdatabase/index.html
index d4dd04e6..c63228bb 100644
--- a/atdb/taskdatabase/templates/taskdatabase/index.html
+++ b/atdb/taskdatabase/templates/taskdatabase/index.html
@@ -44,7 +44,7 @@
     </div>
     {% include 'taskdatabase/pagination.html' %}
 </div>
-    <p class="footer"> Version 1.0.0 (28 jan 2021 - 11:00)
+    <p class="footer"> Version 1.0.0 (29 jan 2021 - 08:00)
     <script type="text/javascript">
         (function(seconds) {
             var refresh,
-- 
GitLab