Diese Präsentation wurde erfolgreich gemeldet.
Wir verwenden Ihre LinkedIn Profilangaben und Informationen zu Ihren Aktivitäten, um Anzeigen zu personalisieren und Ihnen relevantere Inhalte anzuzeigen. Sie können Ihre Anzeigeneinstellungen jederzeit ändern.
MobileCoach – Requirements & Setup
Andreas Filler, M.Sc.
Updated for MobileCoach version 1.3.1
Zurich, Switzerland
Last up...
© Health-IS LabSlide 2 | Andreas Filler | MobileCoach – Requirements & Setup
Agenda
§ System and Software Architecture
§ H...
© Health-IS LabSlide 3 | Andreas Filler | MobileCoach – Requirements & Setup
System Architecture
Mobile Coach Für Entwickl...
© Health-IS LabSlide 4 | Andreas Filler | MobileCoach – Requirements & Setup
Hardware/Server Requirements
§ Stable and saf...
© Health-IS LabSlide 5 | Andreas Filler | MobileCoach – Requirements & Setup
High-Level Software Architecture
Mobile Coach...
© Health-IS LabSlide 6 | Andreas Filler | MobileCoach – Requirements & Setup
Software Architecture
MobileCoach
Server
© Health-IS LabSlide 7 | Andreas Filler | MobileCoach – Requirements & Setup
Software Requirements
Development
(required f...
© Health-IS LabSlide 8 | Andreas Filler | MobileCoach – Requirements & Setup
Software Requirements
Server Setup
(required ...
© Health-IS LabSlide 9 | Andreas Filler | MobileCoach – Requirements & Setup
Server Setup – 1) mongoDB database
Task:
Inst...
© Health-IS LabSlide 10 | Andreas Filler | MobileCoach – Requirements & Setup
mongodb.conf
bind_ip = 127.0.0.1
port = 2701...
© Health-IS LabSlide 11 | Andreas Filler | MobileCoach – Requirements & Setup
Server Setup – 2) mongoDB database
Task:
Cre...
© Health-IS LabSlide 12 | Andreas Filler | MobileCoach – Requirements & Setup
Server Setup – 3) Java Development Kit
Task:...
© Health-IS LabSlide 13 | Andreas Filler | MobileCoach – Requirements & Setup
Server Setup – 4) Tomcat Web Container
Task:...
© Health-IS LabSlide 14 | Andreas Filler | MobileCoach – Requirements & Setup
Server Setup – 5) Tomcat Web Container
Task:...
© Health-IS LabSlide 15 | Andreas Filler | MobileCoach – Requirements & Setup
Software Deployment – 1) Source code
Task:
C...
© Health-IS LabSlide 16 | Andreas Filler | MobileCoach – Requirements & Setup
Software Deployment – 2) Eclipse IDE
Task:
I...
© Health-IS LabSlide 17 | Andreas Filler | MobileCoach – Requirements & Setup
Ant build in Eclipse IDE
1
2
© Health-IS LabSlide 18 | Andreas Filler | MobileCoach – Requirements & Setup
Software Deployment – 3) MobileCoach Configu...
© Health-IS LabSlide 19 | Andreas Filler | MobileCoach – Requirements & Setup
configuration.properties
### Basic configura...
© Health-IS LabSlide 20 | Andreas Filler | MobileCoach – Requirements & Setup
web_configuration.properties
### Website con...
© Health-IS LabSlide 21 | Andreas Filler | MobileCoach – Requirements & Setup
Software Deployment – 4) MobileCoach Backend...
© Health-IS LabSlide 22 | Andreas Filler | MobileCoach – Requirements & Setup
MobileCoach Login Screen
Additional informat...
© Health-IS LabSlide 23 | Andreas Filler | MobileCoach – Requirements & Setup
Andreas Filler, M.Sc.
afiller@ethz.ch
Health...
Nächste SlideShare
Wird geladen in …5
×

MobileCoach - Requirements & Setup

599 Aufrufe

Veröffentlicht am

Detailed instructions what you need and how to setup your own MobileCoach platform on your own server.

Veröffentlicht in: Wissenschaft
  • Als Erste(r) kommentieren

  • Gehören Sie zu den Ersten, denen das gefällt!

MobileCoach - Requirements & Setup

  1. 1. MobileCoach – Requirements & Setup Andreas Filler, M.Sc. Updated for MobileCoach version 1.3.1 Zurich, Switzerland Last update: 2015-11-25
  2. 2. © Health-IS LabSlide 2 | Andreas Filler | MobileCoach – Requirements & Setup Agenda § System and Software Architecture § Hardware and Software Requirements § Server Setup § Software Deployment
  3. 3. © Health-IS LabSlide 3 | Andreas Filler | MobileCoach – Requirements & Setup System Architecture Mobile Coach Für Entwickler Für Anwend Domain Expert Administrator Intervention Participant Intervention Development MobileCoach Server SMS Gateway/Provider (Smart)phone WebApp Email SMS
  4. 4. © Health-IS LabSlide 4 | Andreas Filler | MobileCoach – Requirements & Setup Hardware/Server Requirements § Stable and safe server infrastructure – 64-bit architecture – At least 4 GB RAM – At least 100 GB HDD – Windows, Mac or Linux (recommended) – More resources based on user count and intervention complexity § Reliable backup capabilities § Domain § Server certificate for domain § Safely configured firewall (HTTP, HTTPS, SMTP, SSH)
  5. 5. © Health-IS LabSlide 5 | Andreas Filler | MobileCoach – Requirements & Setup High-Level Software Architecture Mobile Coach Für Entwickler Für Anwend MobileCoach Server Operating System Windows/Mac/Linux Database Runtime Data Access Web Container MobileCoach MobileCoach WebApp
  6. 6. © Health-IS LabSlide 6 | Andreas Filler | MobileCoach – Requirements & Setup Software Architecture MobileCoach Server
  7. 7. © Health-IS LabSlide 7 | Andreas Filler | MobileCoach – Requirements & Setup Software Requirements Development (required for deployment and adjustments) § Any Java-compatible operating system § Java Development Kit 8 or newer § Apache Tomcat 8 or newer § mongoDB database (1.6.x) § Eclipse IDE LUNA or newer § Apache Ivy IDE § GIT Client (e.g. SourceTree) § Project Lombok § Firefox (or comparable) § MobileCoach source code from GIT (mobile-coach.eu)
  8. 8. © Health-IS LabSlide 8 | Andreas Filler | MobileCoach – Requirements & Setup Software Requirements Server Setup (required to run a server) § 64-bit operating system (Linux recommended) § Java Development Kit 8 or newer § Apache Tomcat 8 or newer § mongoDB database (1.6.x) § Text editor § Firefox (or comparable) § MobileCoach WAR file (created in deployment process) § SMS provider account with phone number and credits (e.g. aspsms.com)
  9. 9. © Health-IS LabSlide 9 | Andreas Filler | MobileCoach – Requirements & Setup Server Setup – 1) mongoDB database Task: Installation of mongoDB database Windows: § Download installer from mongodb.org § Execute setup and remember installation path § Adjust data and log path in configuration file (next slide) Mac/Linux: § Download .tgz file from mongodb.org § Extract .tgz archive § Adjust data and log path in configuration file (next slide)
  10. 10. © Health-IS LabSlide 10 | Andreas Filler | MobileCoach – Requirements & Setup mongodb.conf bind_ip = 127.0.0.1 port = 27017 quiet = true dbpath = /MobileCoach/data/mongodb logpath = /MobileCoach/data/logs/mongodb.log logappend = true journal = true nohttpinterface = true master = true # The following two need to be commented out to create (admin) users #auth = true #setParameter = enableLocalhostAuthBypass=0
  11. 11. © Health-IS LabSlide 11 | Andreas Filler | MobileCoach – Requirements & Setup Server Setup – 2) mongoDB database Task: Creation of users and security settings (separate creation of admin user is recommended;see official documentation) 1. Start database with the two last lines commented out in configuration file 2. Create users using mongo command: mongo admin --eval "db.runCommand( { dropAllUsersFromDatabase: 1 } )” mongo admin --eval "db.createUser( { user: 'global', pwd: 'abc123', roles: [ 'clusterAdmin', 'dbAdminAnyDatabase', 'userAdminAnyDatabase', 'readWriteAnyDatabase' ] } )” mongo mc --eval "db.createUser( { user: 'global', pwd: 'abc123', roles: [ 'readWrite' ] } )” 3. Remember user credentials and database 4. Restart database after switching back to regular configuration (with auth=true and enableLocalhostAuthBypass=0)
  12. 12. © Health-IS LabSlide 12 | Andreas Filler | MobileCoach – Requirements & Setup Server Setup – 3) Java Development Kit Task: Installation of Oracle Java DevelopmentKit 8u* Windows: § Download installer from java.oracle.com § Execute setup and remember installation path Mac: § Download installer from java.oracle.com § Execute setup and look up final path at /Library/Java/JavaVirtualMachines/ Linux: § Download .tar archive from java.oracle.com § Extract .tar archive to /opt/Oracle_Java and remember installation path
  13. 13. © Health-IS LabSlide 13 | Andreas Filler | MobileCoach – Requirements & Setup Server Setup – 4) Tomcat Web Container Task: Installation of Apache TomcatWeb Container 8.0 (detailed guides see official documentation) Windows/Mac/Linux: § Download .zip archive from tomcat.apache.org § Extract .zip archive § Enable HTTPS connectorin server.xml for safe communication with own certificate: <Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true" maxThreads="150" scheme="https" secure="true" clientAuth="false" sslProtocol="TLS" keystoreFile="/mc_data/certificate/keystore" keystorePass="abc123"/>
  14. 14. © Health-IS LabSlide 14 | Andreas Filler | MobileCoach – Requirements & Setup Server Setup – 5) Tomcat Web Container Task: Configuration of Apache Tomcat Web Container for MobileCoach 1. Adjust CATALINA_HOME for appropriate installation path 2. Adjust JAVA_HOME for installed JDK (path) 3. Adjust JAVA_OPTS for MobileCoach configuration files (explained later): -Dmc.configuration= /mc_data/configuration/configuration.properties -Dmc_website.configuration= /mc_data/configuration/web_configuration.properties -Dmc_logging_folder=/mc_data/logs -Dmc_logging_console_level=INFO -Dmc_logging_rolling_file_level=INFO 4. Copy created MC.war file to webapps folder (MC.war is resulting file from deploymentsteps)
  15. 15. © Health-IS LabSlide 15 | Andreas Filler | MobileCoach – Requirements & Setup Software Deployment – 1) Source code Task: Checkoutof the MobileCoach source code from the BitBucket repository using your favorite GIT client (e.g. SourceTree) 1. Check out “MobileCoach CORE” from the repository: HTTPS: https://bitbucket.org/mobilecoach/mobilecoach-core.git SSH: git@bitbucket.org:mobilecoach/mobilecoach-core.git 2. Check out “MobileCoach Website” from the repository: HTTPS: https://bitbucket.org/mobilecoach/mobilecoach-website.git SSH: git@bitbucket.org:mobilecoach/mobilecoach-website.git
  16. 16. © Health-IS LabSlide 16 | Andreas Filler | MobileCoach – Requirements & Setup Software Deployment – 2) Eclipse IDE Task: Installation and configuration of Eclipse IDE 1. Download Eclipse for Jave EE Developer for your platform from eclipse.org 2. Install Project Lombok from projectlombok.org in your Eclipse installation by running lombok.jar in a console: java -jar lombok.jar 3. Setup your workspace using wizard after startup 4. Install Apache Ivy IDE using the Eclipse Marketplace inside Eclipse 5. Import the both projects as existing projects into workspace 6. Run the build.xml of both projects as Ant build (in the same JRE) 7. Copy the created web archives (.war) to the Tomcat webapps folder
  17. 17. © Health-IS LabSlide 17 | Andreas Filler | MobileCoach – Requirements & Setup Ant build in Eclipse IDE 1 2
  18. 18. © Health-IS LabSlide 18 | Andreas Filler | MobileCoach – Requirements & Setup Software Deployment – 3) MobileCoach Configuration Task: Configuration of the MobileCoach platform 1. Create copies of the configuration files configuration.properties and web_configuration.properties 2. Adjust both files for your own needs (you need a separate email account for this step) 3. Adjust the Tomcat startup parameters (Server Setup step 5) for the paths to your both own files
  19. 19. © Health-IS LabSlide 19 | Andreas Filler | MobileCoach – Requirements & Setup configuration.properties ### Basic configuration # CAUTION! DO NEVER ACTIVATE THIS ON PUBLIC SERVERS! IT'S ONLY FOR TESTING cachingActive = true # CAUTION! DO NEVER ACTIVATE THIS ON PUBLIC SERVERS! IT'S ONLY FOR TESTING listOpenScreenSurveysOnBaseURL = true mediaObjectLinkingBaseURL = https://f.mobile-coach.eu/ feedbackLinkingBaseURL = https://fb.mobile-coach.eu/ acceptedStopWordsSeparatedByComma = stop,stopp ### Admin configuration defaultAdminUsername = admin defaultAdminPassword = admin # CAUTION! DO NEVER ACTIVATE THIS ON PUBLIC SERVERS! IT'S ONLY FOR DEVELOPMENT automaticallyLoginAsDefaultAdmin = true # CAUTION! DO NEVER ACTIVATE THIS ON PUBLIC SERVERS! IT'S ONLY FOR TESTING adminLocale = EN loggingFolder = /mc_data/logs storageFolder = /mc_data/FileStorage templatesFolder = /mc_data/templates loggingConsoleLevel = INFO loggingRollingFileLevel = INFO fileExtension = .mc ### Survey listing configuration surveyListingTitle = Active surveys: surveyListingNoneActive = No survey active. surveyListingNotActive = Survey listing inactive. ### Statistics configuration statisticsFileEnabled = true statisticsFile = /mc_data/statistics.properties ### Simulation configuration # CAUTION! DO NEVER ACTIVATE THIS ON PUBLIC SERVERS! IT'S ONLY FOR TESTING simulatedDateAndTime = false # CAUTION! DO NEVER ACTIVATE THIS ON PUBLIC SERVERS! IT'S ONLY FOR TESTING smsSimulationNumber = +543210 ### Database configuration databaseHost = 127.0.0.1 databasePort = 27017 databaseUser = mc databasePassword = mc databaseName = mc ### Mailing configuration mailhostIncoming = localhost mailboxProtocol = pop3 mailboxFolder = INBOX mailhostOutgoing = localhost mailUser = --- mailPassword = --- mailSubjectStartsWith = SMS received on ### SMS configuration smsEmailFrom = a@b.eu smsEmailTo = c@d.eu smsUserKey = ABC smsUserPassword = XYZ smsPhoneNumberAcceptedCountryCodes = 41,43,49 smsPhoneNumberCountryCorrection = 41 smsPhoneNumberFrom = +4567890 Currently only aspsms.com is supported as SMS provider
  20. 20. © Health-IS LabSlide 20 | Andreas Filler | MobileCoach – Requirements & Setup web_configuration.properties ### Website configuration websiteDataContentPath = /mc_data/website/content websiteDataFilesPath = /mc_data/website/files # defaultURL must start with www. defaultURL = https://www.your_mc_website.eu # websiteDataURL must start with data. websiteDataURL = https://data.your_mc_website.eu ### Statistics configuration statisticsFile = /mc_data/statistics.properties ### Individual MobileCoach instance specific configuration # The constant #PATH#file# can be used instead of a folder names for feedback, files, etc. specific redirects configuratedSubDomains = fb:#/MC#file#,f:#/MC/files-short#file#,test:example
  21. 21. © Health-IS LabSlide 21 | Andreas Filler | MobileCoach – Requirements & Setup Software Deployment – 4) MobileCoach Backend Task: First login 1. Start using MobileCoach in your favorite web browser (e.g. Firefox) by visiting https://YOUR_ADDRESS:8443/MC/admin 2. Use the admin login data you provided in the configuration file as default for your first login 3. Change the password of the admin user 4. Enjoy the MobileCoach platform! The default website shipped with the MobileCoach Website package can be found on the root URL and can be changed using the WebContent/www folder of the project as well as using https://YOUR_ADDRESS:8443/admin as regular tomcat user with the role mobile-coach
  22. 22. © Health-IS LabSlide 22 | Andreas Filler | MobileCoach – Requirements & Setup MobileCoach Login Screen Additional information on the setup process can be found in the README.md files in the root of both projects!
  23. 23. © Health-IS LabSlide 23 | Andreas Filler | MobileCoach – Requirements & Setup Andreas Filler, M.Sc. afiller@ethz.ch Health-IS Lab, University St. Gallen & ETH Zurich www.HealthIS.ch www.mobile-coach.eu Team Prof. Dr. Elgar Fleisch Tobias Kowatsch, M.Sc. Dipl.-Winf. Dirk Volland Dipl.-Psych.Flavius Kehr Andreas Filler, M.Sc. Fabian Wahle,M.Sc. Contact

×