SEARCH-1699 Deleting unwanted docker-compose templates

This commit is contained in:
sridharvellingiri
2019-06-25 16:03:49 +01:00
parent cd97486900
commit 24bf03b498
5 changed files with 93 additions and 0 deletions

View File

@@ -0,0 +1,11 @@
# docker-compose related environments
ALFRESCO_IMAGE=alfresco/alfresco-content-repository
ALFRESCO_TAG=6.1.0-EA3
SHARE_IMAGE=alfresco/alfresco-share
SHARE_TAG=6.0
POSTGRES_IMAGE=postgres
POSTGRES_TAG=10.1
SEARCH_IMAGE=quay.io/alfresco/search-services
SEARCH_TAG=latest
ACTIVEMQ_IMAGE=alfresco/alfresco-activemq
ACTIVEMQ_TAG=5.15.6

View File

@@ -0,0 +1,41 @@
include ../../Makefile
include .env
# CURRENT_DIR is the folder where this Makefile is saved
CURRENT_DIR:=$(shell dirname $(realpath $(lastword $(MAKEFILE_LIST))))
ifeq ($(dc-upgrade),)
dc-upgrade:=$(dc) -f ../docker-compose.yml -f docker-compose.upgrade.yml
endif
## ---- UPGRADE
set_version ?=latest # default version that will be used in tasks
as-previous: clean ## 1 - install the previous version: $ make set_version=1.2.1 as-previous
rm -rf ./solr-data && \
rm -rf ./solr-contentstore && \
rm -f ./image-digests.txt
export SEARCH_TAG=$(set_version) && \
$(dc-upgrade) pull && \
echo "\n====Previous====" > image-digests.txt && \
$(dc-upgrade) config --resolve-image-digests >> image-digests.txt && \
$(dc-upgrade) up -d && \
docker ps
as-current: ## 2 - upgrade previous to this version $ make set_version=2.0.x as-current
$(dc-upgrade) kill search && \
$(dc-upgrade) rm -f search && \
export SEARCH_TAG=$(set_version) && \
$(dc-upgrade) pull search && \
echo "\n====Current====" >> image-digests.txt && \
$(dc-upgrade) config --resolve-image-digests >> image-digests.txt && \
$(dc-upgrade) up -d search && \
docker ps
#
# Run the following commands if you need to test the upgrade e2e
#
#make set_version=1.2.1 as-previous wait
#make run-mvn-tests suiteXmlFile=./src/test/resources/search-pre-upgrade-suite.xml
#make set_version=2.0.x as-current wait
#make run-mvn-tests suiteXmlFile=./src/test/resources/search-post-upgrade-suite.xml

View File

@@ -0,0 +1,31 @@
# About
Testing the Upgrade of SearchService product
**Build Plan:** https://bamboo.alfresco.com/bamboo/browse/SAD-QAUP
![](docs/upgrade.png?raw=true)
# Steps
* **a)** start the initial version
```shel
make set_version=1.2.1 as-previous wait
```
>notice that new folders will appear on you "upgrade" folder with data from container(s)
* **b)** create some data manually or using automated tests found on this project
```shel
make run-mvn-tests suiteXmlFile=./src/test/resources/search-pre-upgrade-suite.xml
```
* **c)** now upgrade to new version
```shel
make set_version=2.0.x as-current wait
```
* **d)** and test that upgrade data exist
```shel
make run-mvn-tests suiteXmlFile=./src/test/resources/search-post-upgrade-suite.xml
```
# Environment Settings
Pay attention at the values that exist in [.env](.env) file. These settings will be picked up in custom docker-compose.*.yml file(s)

View File

@@ -0,0 +1,10 @@
version: '3'
services:
search:
environment:
- VERSION=${SEARCH_TAG}
image: quay.io/alfresco/search-services:${SEARCH_TAG}
volumes:
- "./upgrade/solr-data:/opt/alfresco-search-services/data"
- "./upgrade/solr-contentstore:/opt/alfresco-search-services/contentstore"

Binary file not shown.

After

Width:  |  Height:  |  Size: 216 KiB