diff --git a/Dockerfile b/Dockerfile index 00304102..f8b2f3f3 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,15 +1,10 @@ -FROM centos:6.6 +FROM centos -ENV JAVA_VERSION_MAJOR=8 \ - JAVA_VERSION_MINOR=171 \ - JAVA_VERSION_BUILD=11 \ - JAVA_URL_HASH=512cd62ec5174c3487ac17c61aaa89e8 +RUN cd /etc/yum.repos.d/ +RUN sed -i 's/mirrorlist/#mirrorlist/g' /etc/yum.repos.d/CentOS-* +RUN sed -i 's|#baseurl=http://mirror.centos.org|baseurl=http://vault.centos.org|g' /etc/yum.repos.d/CentOS-* -RUN yum install -y wget && \ - wget -q --no-cookies --no-check-certificate \ - --header 'Cookie:oraclelicense=accept-securebackup-cookie' \ - "http://download.oracle.com/otn-pub/java/jdk/${JAVA_VERSION_MAJOR}u${JAVA_VERSION_MINOR}-b${JAVA_VERSION_BUILD}/${JAVA_URL_HASH}/jre-${JAVA_VERSION_MAJOR}u${JAVA_VERSION_MINOR}-linux-x64.rpm" && \ - yum install -y jre-${JAVA_VERSION_MAJOR}u${JAVA_VERSION_MINOR}-linux-x64.rpm && rm -f jre-*.rpm && yum clean all +RUN yum install java-1.8.0-openjdk -y COPY mci-api/build/distributions/mci-*.noarch.rpm /tmp/mci.rpm RUN yum install -y /tmp/mci.rpm && rm -f /tmp/mci.rpm && yum clean all diff --git a/env/docker_mci b/env/docker_mci index 8d1d29a8..d9c85f7a 100644 --- a/env/docker_mci +++ b/env/docker_mci @@ -41,4 +41,4 @@ export SEARCH_MAPPING_TASK_BLOCK_SIZE=10 export MAX_FAILED_EVENTS=5 export FAILED_EVENT_RETRY_LIMIT=5 export MCI_ORG_CODE=10019862 -export IS_MCI_MASTER_NODE=false +export IS_MCI_MASTER_NODE=true diff --git a/env/local.properties b/env/local.properties index 34fe78b7..94adeaa6 100644 --- a/env/local.properties +++ b/env/local.properties @@ -11,9 +11,9 @@ REST_POOL_SIZE=20 MCI_PORT=8081 API_VERSION=v1 IS_LATEST_API_VERSION=true -FR_URL=http://hrmtest.dghs.gov.bd/api/1.0/facilities -PR_URL=http://hrmtest.dghs.gov.bd/api/1.0/providers -IDENTITY_SERVER_BASE_URL=http://172.18.46.55:8084/ +FR_URL=http://localhost:8084/api/1.0/facilities +PR_URL=http://localhost:8084/api/1.0/providers +IDENTITY_SERVER_BASE_URL=http://localhost:8084/ IDENTITY_SERVER_SIGNIN_PATH=signin IDENTITY_SERVER_USER_INFO_PATH=token FR_CACHE_TTL=86400 @@ -24,10 +24,10 @@ IDP_CLIENT_PASSWORD=thoughtworks IDP_AUTH_TOKEN=b43d2b284fa678fb8248b7cc3ab391f9c21e5d7f8e88f815a9ef4346e426bd33 WORKER_ID=1 MCI_LOG_LEVEL=INFO -SERVER_URL=http://192.168.33.19:8081 +SERVER_URL=http://localhost:8081 DUPLICATE_PATIENT_FEED_DELAY=10000 DUPLICATE_PATIENT_FEED_INITIAL_DELAY=10000 -HID_SERVICE_BASE_URL=http://localhost:9082 +HID_SERVICE_BASE_URL=http://localhost:8086 HID_SERVICE_NEXT_BLOCK_URL=/healthIds/nextBlock/mci/%s?blockSize=%s HID_SERVICE_CHECK_HID_URL=/healthIds/checkAvailability/%s?orgCode=%s HEALTH_ID_REPLENISH_DELAY=60000 @@ -41,4 +41,4 @@ SEARCH_MAPPING_TASK_BLOCK_SIZE=10 MAX_FAILED_EVENTS=5 FAILED_EVENT_RETRY_LIMIT=5 MCI_ORG_CODE=10019862 -IS_MCI_MASTER_NODE=false +IS_MCI_MASTER_NODE=true diff --git a/mci-domain/src/main/java/org/sharedhealth/mci/domain/model/PatientData.java b/mci-domain/src/main/java/org/sharedhealth/mci/domain/model/PatientData.java index 85c71671..03d7a302 100644 --- a/mci-domain/src/main/java/org/sharedhealth/mci/domain/model/PatientData.java +++ b/mci-domain/src/main/java/org/sharedhealth/mci/domain/model/PatientData.java @@ -52,7 +52,7 @@ public class PatientData implements Diffable { @JsonProperty(NID) @JsonInclude(NON_EMPTY) - @Pattern(regexp = "^|[\\d]{13}|[\\d]{17}", message = ERROR_CODE_PATTERN) + @Pattern(regexp = "^|[\\d]{13}|[\\d]{17}|[\\d]{10}", message = ERROR_CODE_PATTERN) private String nationalId; @JsonProperty(BIN_BRN)