Advertisement
Guest User

Untitled

a guest
Apr 19th, 2017
956
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.78 KB | None | 0 0
  1. #!/bin/bash
  2.  
  3. SECONDS=0;
  4. rm -rf app/cache/prod app/cache/Temp
  5.  
  6. DB=$(sed -n -e 's/^.*database_name: //p' app/config/parameters.yml) && \
  7. DB_USER=$(sed -n -e 's/^.*database_user: //p' app/config/parameters.yml) && \
  8. MYSQL_PWD=$(sed -n -e 's/^.*database_password: //p' app/config/parameters.yml);
  9.  
  10. mysql -e "drop database $DB;" -u $DB_USER && mysql -e "create database $DB;" -u $DB_USER;
  11.  
  12. sed -i -e 's/installed: .*$/installed: null/g' app/config/parameters.yml
  13.  
  14. app/console oro:install --drop-database --user-name=admin \
  15. --user-email=admin@example.com --user-firstname=John \
  16. --user-lastname=Doe --user-password=admin --organization-name=ORO \
  17. --env=prod --sample-data=n --timeout=3000 \
  18. --application-url=$1;
  19.  
  20. duration=$SECONDS;
  21. echo $(date -u -d @"$duration" +'%-Mm %-Ss elapsed.');
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement