Skip to content

I-TECH-UW/SGS-O3

Repository files navigation

SGS OpenMRS 3.0 Application

A containerized deployment of OpenMRS 3.0 with custom configurations for the SGS healthcare system.

🌐 Overview

This repository contains the build configuration for the SGS OpenMRS 3.0 application, deployed at sgs.uwdigi.org.

🚀 Quick Start

Prerequisites

  • Docker and Docker Compose
  • Git
  • Access to SMS API credentials
  • OpenMRS user credentials

Installation

  1. Clone the repository:

    git clone https://github.com/your-org/sgs-openmrs
    cd sgs-openmrs
  2. Set up environment variables:

    cp .env.example .env
  3. Configure the following in .env:

    • SMS API credentials (USERNAME and API KEY)
    • OpenMRS user credentials
    • OpenMRS Questionnaire API endpoint URL
  4. Start the application:

    docker compose up --build

💾 Database Management

Backup and Restore

To restore from a backup:

  1. Place your SQL backup file in the db folder
  2. Update the following configurations in .env:
    OMRS_CONFIG_AUTO_UPDATE_DATABASE=false
    OMRS_CONFIG_CREATE_TABLES=false
  3. Restart the application:
    docker compose down
    docker compose up --build

Creating a Backup

docker exec sgs-mariadb mysqldump -u$MYSQL_USER -p$MYSQL_PASSWORD openmrs > backup_$(date +%Y%m%d).sql

🧹 Cleanup

To completely remove the application and its volumes:

docker compose -p sgs_emr down -v

🔧 Configuration

Key configuration files:

  • docker-compose.yml: Container orchestration
  • .env: Environment variables
  • db/: Database initialization scripts

🛟 Troubleshooting

Common issues and solutions:

  1. Database connection errors:

    • Verify MariaDB container is running
    • Ensure proper network connectivity
  2. SMS API issues:

    • Validate API credentials
    • Check network connectivity to SMS service
    • Review API endpoint configuration

📚 Additional Resources

🤝 Contributing

  1. Fork the repository
  2. Create your feature branch
  3. Commit your changes
  4. Push to the branch
  5. Create a new Pull Request

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published