diff --git a/Makefile b/Makefile index 2fc9159a86..7bf94508e6 100644 --- a/Makefile +++ b/Makefile @@ -227,20 +227,22 @@ impl-dev.provision.%: dev.check-memory ## Provision specified services. dev.provision.%: ## Provision specified services. @scripts/send_metrics.py wrap "dev.provision.$*" -dev.backup: dev.up.mysql57+mongo+elasticsearch+elasticsearch7+elasticsearch710+coursegraph ## Write all data volumes to the host. +dev.backup: dev.up.mysql57+mongo+elasticsearch+elasticsearch7+elasticsearch710+opensearch12+coursegraph ## Write all data volumes to the host. docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.mysql57) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zcvf /backup/mysql57.tar.gz /var/lib/mysql docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.mongo) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zcvf /backup/mongo.tar.gz /data/db docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.elasticsearch) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zcvf /backup/elasticsearch.tar.gz /usr/share/elasticsearch/data docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.elasticsearch7) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zcvf /backup/elasticsearch7.tar.gz /usr/share/elasticsearch/data docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.elasticsearch710) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zcvf /backup/elasticsearch710.tar.gz /usr/share/elasticsearch/data + docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.opensearch12) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zcvf /backup/opensearch12.tar.gz /usr/share/opensearch/data docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.coursegraph) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zcvf /backup/coursegraph.tar.gz /data -dev.restore: dev.up.mysql57+mongo+elasticsearch+elasticsearch7+elasticsearch710+coursegraph ## Restore all data volumes from the host. WILL OVERWRITE ALL EXISTING DATA! +dev.restore: dev.up.mysql57+mongo+elasticsearch+elasticsearch7+elasticsearch710+opensearch12+coursegraph ## Restore all data volumes from the host. WILL OVERWRITE ALL EXISTING DATA! docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.mysql57) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zxvf /backup/mysql57.tar.gz docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.mongo) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zxvf /backup/mongo.tar.gz docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.elasticsearch) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zxvf /backup/elasticsearch.tar.gz docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.elasticsearch7) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zxvf /backup/elasticsearch7.tar.gz docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.elasticsearch710) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zxvf /backup/elasticsearch710.tar.gz + docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.opensearch12) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zxvf /backup/opensearch12.tar.gz docker run --rm --volumes-from $$(make --silent --no-print-directory dev.print-container.coursegraph) -v $$(pwd)/.dev/backups:/backup debian:jessie tar zxvf /backup/coursegraph.tar.gz # List of Makefile targets to run database migrations, in the form dev.migrate.$(service) diff --git a/docker-compose.yml b/docker-compose.yml index 0d5c39f152..aacd02aa74 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -118,6 +118,25 @@ services: - bootstrap.memory_lock=true - "ES_JAVA_OPTS=-Xms512m -Xmx512m" + # This is meant to be used to test OS upgrades. + opensearch12: + container_name: "edx.${COMPOSE_PROJECT_NAME:-devstack}.opensearch12" + hostname: opensearch12.devstack.edx + image: opensearchproject/opensearch:1.2.0 + networks: + default: + aliases: + - edx.devstack.opensearch12 + ports: + - "9202:9200" + - "9600:9600" + volumes: + - opensearch12_data:/usr/share/opensearch/data + environment: + - discovery.type=single-node + - bootstrap.memory_lock=true + - "ES_JAVA_OPTS=-Xms512m -Xmx512m" + firefox: container_name: "edx.${COMPOSE_PROJECT_NAME:-devstack}.firefox" hostname: firefox.devstack.edx @@ -396,6 +415,7 @@ services: - memcached - mongo - elasticsearch710 + - opensearch12 image: edxops/forum:${OPENEDX_RELEASE:-latest} stdin_open: true tty: true @@ -418,6 +438,7 @@ services: - memcached - mongo - mysql57 + - opensearch12 # Allows attachment to the LMS service using 'docker attach '. stdin_open: true tty: true @@ -577,6 +598,7 @@ services: - memcached - mongo - mysql57 + - opensearch12 # Allows attachment to the Studio service using 'docker attach '. stdin_open: true tty: true @@ -814,4 +836,5 @@ volumes: elasticsearch7_data: elasticsearch710_data: mongo_data: + opensearch12_data: mysql57_data: diff --git a/options.mk b/options.mk index fdf913a61a..dc2b453001 100644 --- a/options.mk +++ b/options.mk @@ -90,4 +90,4 @@ credentials+discovery+ecommerce+insights+lms+registrar+studio # All third-party services. # Separated by plus signs. Listed in alphabetical order for clarity. THIRD_PARTY_SERVICES ?= \ -chrome+coursegraph+devpi+elasticsearch+elasticsearch7+elasticsearch710+firefox+memcached+mongo+mysql57+redis+namenode+datanode+resourcemanager+nodemanager+sparkmaster+sparkworker+vertica +chrome+coursegraph+devpi+elasticsearch+elasticsearch7+elasticsearch710+firefox+memcached+mongo+mysql57+opensearch12+redis+namenode+datanode+resourcemanager+nodemanager+sparkmaster+sparkworker+vertica