SSL Certifikat za yacy
https://github.com/yacy/yacy_search_server/issues/194
Letsencript
– install certboot
– open port 80 – certboot ima http server – opcija –standalone
– generirat certifikat:
sudo certbot certonly --standalone -d example.com
sudo certbot certonly --standalone -d comanet.ddns.net
– Certifkat je sada u /etc/letsencrypt/live/comanet.ddns.net/
– Konvertirat Certifikat
– use openssl to convert them into yacy-readable format:
– generira keystore.pkcs12 u ordneru gdje se nalazis pa je zato najbolje biti u /DATA/SETTINGS kad knvertiras
openssl pkcs12 -export -out keystore.pkcs12 -passout pass:pass -in /etc/letsencrypt/live/example.com/cert.pem -inkey /etc/letsencrypt/live/example.com/privkey.pem -certfile /etc/letsencrypt/live/example.com/fullchain.pem
sudo openssl pkcs12 -export -out letsencrypt.pkcs12 -in /etc/letsencrypt/live/comanet.ddns.net/cert.pem -inkey /etc/letsencrypt/live/comanet.ddns.net/privkey.pem -certfile /etc/letsencrypt/live/comanet.ddns.net/fullchain.pem
– Ako se ne nalazis u /DATA/SETTINGS kopiraj:
– yacy_search_server/DATA/SETTINGS/keystore.pkcs12
– update the yacy conf in <YaCy-Dir>/DATA/SETTINGS/yacy.conf:
keyStore= keyStoePassword= pkcs12ImportFile = DATA/SETTINGS/keystore.pkcs12 pkcs12ImportPwd = pass
Next starts
As attached process
docker start -a yacy
As background process
docker start yacy
Shutdown
Use “Shutdown” button in administration web interface
OR run :
docker exec [your_container_name] /opt/yacy_search_server/stopYACY.sh
OR run :
docker stop [your_container_name]
Upgrade
You can upgrade your YaCy container the Docker way with the following commands sequence.
Get latest Docker image :
docker pull luccioman/yacy:latest
OR
docker pull luccioman/yacy:latest-alpine
Create new container based on pulled image, using volume data from old container :
docker create --name [tmp-container_name] -p 8090:8090 -p 8443:8443 --volumes-from=[container_name] --log-opt max-size=100m --log-opt max-file=2 luccioman/yacy:latest
Stop old container :
docker exec [container_name] /opt/yacy_search_server/stopYACY.sh
Start new container :
docker start [tmp-container_name]
Check everything works fine, then you can delete old container :
docker rm [container_name]
Rename new container to reuse same container name :
docker rename [tmp-container_name] [container_name]
https://notiz.comanet.xyz/?p=593