Skip to content

[Tech] Docker notes , version 3.32

Ingi Erli edited this page Oct 25, 2019 · 1 revision

3.32 Snapshot.


Initial step:

1. Replace the application.yml file found in seqdb.web/src/main/resources with the application.yml file found in the Downloads repository on Bitbucket (https://bitbucket.org/aafc-mbb/seqdb/downloads/)

NOTE 1 : start up database and adminer

  1. 'docker-compose up -d db'
  2. 'docker-compose up -d adminer'
  3. localhost:18080 , login and create schema 'seqdb'

NOTE 2 : from 'adminer' , run the commands

  1. REVOKE CONNECT ON DATABASE seqdb_prod FROM PUBLIC;

  2. REVOKE CREATE ON SCHEMA public FROM PUBLIC;

  3. create schema from 'adminer' : localhost:18080 -> ( Create seqdb schema -> CREATE SCHEMA seqdb;)

NOTE 3 : createUsersSetPrivileges.sql

  1. Create roles using createUsersSetPrivileges.sql (https://bitbucket.org/aafc-mbb/seqdb/downloads/createUsersSetPrivileges.sql) 1.1 Add the SQL-Commands from the 'createUsersSetPrivileges.sql'-file

NOTE 4 : build the tables

  1. Start docker-seqdb -> builds the tables in the 'seqdb'-schema.

NOTE 5 : add data from the insertSeqdbUsers.sql

  1. Add users to seqdb by running insertSeqdbUsers.sql (https://bitbucket.org/aafc-mbb/seqdb/downloads/insertSeqdbUsers.sql)

1.1 insert into seqdb.people (NameFamily, NameGiven,LastModified) values ('admin','admin','2019-01-01'), ('user','user','2019-01-01');

1.2 insert into seqdb.accounts (PeopleID,AccountName,AccountPw,AccountStatus,AccountType,ApiKey,LastModified) values (1,'Admin','$2a$10$2AdGg40oWZdmL288StGGhO88VPXGOv6K548k8DbfRhza1rrkbnuci','Active','Admin','adminkey','2019-01-01'), (2,'User','$2a$10$xWykm3LUauNxthMDhfXGfeeYFVsvVaN5uJk8C.1oTVV77ea0.nT4a','Active','User','userkey','2019-01-01');

1.3 insert into seqdb.groups (GroupName,DefaultRights,LastModified) values ('Admin Group','0000','2019-01-01'), ('User Group','0000','2019-01-01'), ('CNC Loan Diptera','0000','2019-01-01'), ('CNC Loan General','0000','2019-01-01'), ('CNC Loan Staff','0000','2019-01-01'), ('CNC Loan Client','0000','2019-01-01'), ('Public','1000','2019-01-01');

1.4 insert into seqdb.accountsgroups (AccountID,GroupID,Rights,Admin,LastModified) values (1,1,'1111','true','2019-01-01'), (2,2,'1111','true','2019-01-01');

1.5 insert into seqdb.accountprofiles (AccountID,LastModified) values (1,'2019-01-01'), (2,'2019-01-01');


NOTE 6 : verify login

  1. Username: Admin
  2. Password: Admin

NOTE 7 : verify the 'specimen'-link and the 'sample'-link

  1. login
  2. click the 'Specimens'-link
  3. click the 'Samples'-link

NOTE 8 : verify the import of specimens and import of samples.

  1. generic config but .... referring to the 'sample_working.xlsx'

  2. Create a 'Group': 'NRM-DNA' (all rights)

  3. Create a 'Specimen Collection': 'specimen collection' -> 'LARHED' (chosen group-name='NRM-DNA')

  4. import specimen-file: https://github.com/CGI-NRM/SeqDB-documentation/blob/master/sample-files/dna-lab/specimen_working.xlsx

  5. verify-1 the import of the specimen file : result=OK (96 records)

  6. verify-2 the import of the specimen file : press the 'Specimens'-link : Result=OK (96 records)

  7. Create a 'storage Container Type' group name = NRM-DNA, container type name = 96well, container type = 'micronic 96 barcoded', number of columns = 12, number of rows = 8, total numbers of wells = 96

  8. Add a 'storage container' group name = NRM-DNA, container name = 3000142933 , container type = 96well

  9. import the sample-file : https://github.com/CGI-NRM/SeqDB-documentation/blob/master/sample-files/dna-lab/sample_working.xlsx

  10. verify-1 the import of the sample file : result=OK (96 records)

  11. verify-2 the import of the sample file : press the 'Samples'-link : Result=OK (96 records)

  12. verify-3 press the 'Samples'-link : press the first record 'D1305' (Result=OK) , view of the 'rack' (Result=OK)

Clone this wiki locally