Commit d72d5ff3 authored by François Agneray's avatar François Agneray
Browse files

Add create-db shell script

parent 7235d8af
......@@ -59,10 +59,7 @@ phpcs:
-w /project jakzal/phpqa phpcs --standard=PSR12 --extensions=php --colors src tests
create-db:
@docker-compose exec php ./vendor/bin/doctrine orm:schema-tool:create
dev-meta:
@docker-compose exec php sh ./conf-dev/dev-meta.sh
@docker-compose exec php sh ./conf-dev/create-db.sh
remove-pgdata:
@docker volume rm anis-server_pgdata
#!/bin/sh
set -e
# Create the settings database (only tables)
./vendor/bin/doctrine orm:schema-tool:create
curl -d '{"label":"Test","dbname":"anis_test","dbtype":"pdo_pgsql","dbhost":"db","dbport":5432,"dblogin":"anis","dbpassword":"anis"}' -H "Content-Type: application/json" -X POST http://localhost/database
curl -d '{"name":"anis_project","label":"Anis Project Test","description":"Project used for testing","link":"http://project.com","manager":"M. Durand","id_database":1}' -H "Content-Type: application/json" -X POST http://localhost/project
......@@ -8,3 +11,7 @@ curl -d '{"label":"Default dataset family","display":10}' -H "Content-Type: appl
curl -d '{"name":"default","label":"Default instance","client_url":"http://localhost:4200"}' -H "Content-Type: application/json" -X POST http://localhost/instance
curl -d '{"name":"obs_cat","table_ref":"obs_cat","label":"ObsCat dataset","description":"ObsCat","display":"10","count":"10000","vo":false,"data_path":"/mnt/mount","selectable_row":true,"project_name":"anis_project","id_dataset_family":1}' -H "Content-Type: application/json" -X POST http://localhost/instance/default/dataset
curl -d '{"name":"observations","table_ref":"observations_info","label":"Observations dataset","description":"Observations","display":"20","count":"177454","vo":false,"data_path":"/mnt/mount","selectable_row":false,"project_name":"anis_project","id_dataset_family":1}' -H "Content-Type: application/json" -X POST http://localhost/instance/default/dataset
curl -d '{"label":"Default criteria family","display":10}' -H "Content-Type: application/json" -X POST http://localhost/family/criteria
curl -d '{"label":"Default output family","display":10}' -H "Content-Type: application/json" -X POST http://localhost/family/output
curl -d '{"label":"Default output category","display":10,"id_output_family":1}' -H "Content-Type: application/json" -X POST http://localhost/output-category
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment