Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...
Loading...

tar --extract \
--gzip \
--verbose \
--same-owner \
--preserve-permissions \
--file=/path/to/snow-owl-linux-x86_64.tar.gz \
--directory=/opt/repository:
index:
socketTimeout: 60000
clusterUrl: https://my-es-cluster.elastic-cloud.com:9243
clusterUsername: my-es-cluster-user
clusterPassword: my-es-cluster-pwd.
└── analysis
└── synonym.txt
snow-owl/
├── backup
├── docker
│ ├── configs
│ │ ├── cert
│ │ │ ├── conf.d
│ │ │ ├── docker-compose-cert.yml
│ │ │ ├── docker-compose.yml
│ │ │ ├── init-certificate.sh
│ │ │ └── nginx.conf
│ │ ├── elasticsearch
│ │ │ └── elasticsearch.yml
│ │ ├── ldap-boostrap
│ │ │ ├── 100_groups.ldif
│ │ │ └── 200_users.ldif
│ │ ├── mysql
│ │ │ └── mysqld.cnf
│ │ ├── nginx
│ │ │ ├── conf.d
│ │ │ │ ├── bugzilla.conf
│ │ │ │ └── snowowl.conf
│ │ │ └── nginx.conf
│ │ └── snowowl
│ │ ├── snowowl.yml
│ │ └── users
│ ├── docker-compose.yml
│ ├── docker_login.txt
│ └── .env
├── ldap
├── logs
└── resources
└── indexes
[root@host docker]# docker-compose ps -a[root@host ~]# docker-compose --file /opt/snow-owl/docker/docker-compose.yml ps -a[root@host]# pwd
/opt/snow-owl/docker/configs/cert
[root@host]# chmod +x init-certificate.sh
[root@host]# ./init-certificate.sh -h
DESCRIPTION:
Get certificate for the specified domain name using Let's Encrypt and certbot
OPTIONS:
-h
Show this help
-d domain
Define the domain name to get the certificate for
-e email (optional)
The email address to use for the certificate registration
EXAMPLES:
./init-certificate.sh -d mywebsite.com -e [email protected]
./init-certificate.sh -d example.com
./init-certificate.sh -d snow-owl.b2ihealthcare.com -e [email protected] nginx:
image: nginx:stable
container_name: nginx
volumes:
- ./configs/nginx/conf.d/:/etc/nginx/conf.d/
- ./configs/nginx/nginx.conf:/etc/nginx/nginx.conf
- ${CERT_FOLDER}/conf:/etc/letsencrypt
- ${CERT_FOLDER}/www:/var/www/certbot
depends_on:
- snowowl
ports:
- "80:80"
- "443:443"
# Reload nginx config every 6 hours and restart
command: "/bin/sh -c 'while :; do sleep 6h & wait $${!}; nginx -s reload; done & nginx -g \"daemon off;\"'"
restart: unless-stopped
certbot:
image: certbot/certbot:latest
container_name: certbot
volumes:
- ${CERT_FOLDER}/conf:/etc/letsencrypt
- ${CERT_FOLDER}/www:/var/www/certbot
# Check for SSL cert renewal every 12 hours
entrypoint: "/bin/sh -c 'trap exit TERM; while :; do certbot renew; sleep 12h & wait $${!}; done;'"
restart: unless-stoppedtar --extract \
--gzip \
--verbose \
--same-owner \
--preserve-permissions \
--file=snow-owl-resources.tar.gz \
--directory=/opt/snow-owl/resources/
chown -R 1000:0 /opt/snow-owl/resources














htpasswd -nBC 10 my-new-username | head -n1 | sed 's/$2y/$2a/g' >> ./snow-owl/docker/configs/snowowl/usersBACKUP_FOLDER=/mnt/external_folder
NUMBER_OF_DAILY_BACKUPS_TO_KEEP=10
CRON_DAYS=Tue-Sat
CRON_HOURS=2
CRON_MINUTES=0root@host:/# docker exec -it backup bash
root@ad36cfb0448c:/# /backup/backup.sh -l my-backup-label./init-certificate.sh -d snow-owl.example.comchmod -R 1000:0 ./snow-owl/docker ./snow-owl/logs ./snow-owl/resourcescat docker_login.txt | docker login -u <username> --password-stdin https://docker.b2i.sgdocker-compose pulldocker-compose up -dcurl https://snow-owl.example.com/snowowl/infocurl http://hostname:8080/snowowl/infocurl https://snow-owl.example.com/bugzillacurl http://hostname:8080/bugzilladocker-compose stop snowowl elasticsearch ldapmv -t /tmp ./snow-owl/resources/indexes/nodesdocker-compose start elasticsearchroot@host:# docker exec -it backup bash
root@ad36cfb0448c:# /backup/restore.shroot@ad36cfb0448c:# /backup/restore.sh
################################
Snow Owl restore script STARTED.
#### Verify Elasticsearch snapshot repository ####
Checking existence of repository 'snowowl-snapshots' ...
Repository with name 'snowowl-snapshots' is present, verifying repository state ...
Repository 'snowowl-snapshots' is functional
#### Select backup to restore ####
Found 10 available backups under '/backup'
Please select the backup to restore by choosing the right number in the menu below (hit Enter when the selection was made)
1) snowowl-daily-20220323030001
2) snowowl-daily-20220324030001
3) snowowl-daily-20220325030002
4) snowowl-daily-20220326030002
5) snowowl-daily-20220329030001
6) snowowl-daily-20220330030001
7) snowowl-daily-20220331030002
8) snowowl-daily-20220401030002
9) snowowl-daily-20220402030001
10) snowowl-daily-20220405030002
#?
root@ad36cfb0448c:# exit
root@host:# docker-compose stop snowowl elasticsearch ldap bugzilla
root@host:# docker-compose up -droot@host:# docker exec -it backup bash
root@ad36cfb0448c:# /backup/restore.sh -lroot@host:# docker exec -it backup bash
root@ad36cfb0448c:# /backup/restore.sh -broot@host:# docker exec -it backup bash
root@ad36cfb0448c:# /backup/restore.sh -b -l[root@host]# diff /opt/snow-owl/docker/ /opt/new-snow-owl-release/snow-owl/docker/
Common subdirectories: /opt/snow-owl/docker/configs and /opt/new-snow-owl-release/snow-owl/docker/configs
diff /opt/snow-owl/docker/.env /opt/new-snow-owl-release/snow-owl/docker/.env
10c10
< ELASTICSEARCH_VERSION=7.12.0
---
> ELASTICSEARCH_VERSION=7.16.3
24c24
< SNOWOWL_VERSION=7.18.0
---
> SNOWOWL_VERSION=7.19.0
docker-compose pull
docker-compose up -d