v19: перевод, история записей (IndexedDB), стерео из истории, фонетический анализ, индикатор микрофона
This commit is contained in:
Executable
+25
@@ -0,0 +1,25 @@
|
||||
#!/bin/bash
|
||||
set -e
|
||||
|
||||
# Вклеиваем Groq API ключ в index.html
|
||||
KEY=$(cat ~/lang/token.txt)
|
||||
cp ~/lang/index.html /tmp/lyngvo_index.html
|
||||
sed -i "s|const GROQ_API_KEY = '';|const GROQ_API_KEY = '${KEY}';|" /tmp/lyngvo_index.html
|
||||
|
||||
# Синхронизация всей папки lang на ВМ
|
||||
rsync -az -e "ssh -i ~/.ssh/naeel_vm_id_ed25519 -o StrictHostKeyChecking=no -o ConnectTimeout=10" ~/lang/ naeel@5.172.178.213:~/terra/lang/
|
||||
|
||||
# Деплой на ВМ (index.html с ключом — через временный файл)
|
||||
scp -i ~/.ssh/naeel_vm_id_ed25519 -o StrictHostKeyChecking=no -o ConnectTimeout=10 /tmp/lyngvo_index.html naeel@5.172.178.213:~/terra/lang/index.html
|
||||
ssh -i ~/.ssh/naeel_vm_id_ed25519 -o StrictHostKeyChecking=no -o ConnectTimeout=10 naeel@5.172.178.213 '
|
||||
cd ~/terra/lang && \
|
||||
kubectl create configmap lyngvo-html --from-file=index.html -n default --dry-run=client -o yaml | kubectl apply -f - && \
|
||||
kubectl create configmap lyngvo-nginx --from-file=default.conf=nginx.conf -n default --dry-run=client -o yaml | kubectl apply -f - && \
|
||||
kubectl apply -f k8s/deployment.yaml && \
|
||||
kubectl apply -f k8s/ingress.yaml && \
|
||||
kubectl rollout restart deploy/lyngvo -n default && \
|
||||
kubectl rollout status deploy/lyngvo -n default --timeout=60s
|
||||
'
|
||||
|
||||
rm -f /tmp/lyngvo_index.html
|
||||
echo "\n=== Деплой завершён. Проверяй capire.kube5s.ru ==="
|
||||
Reference in New Issue
Block a user