-
Notifications
You must be signed in to change notification settings - Fork 0
36 lines (29 loc) · 1.15 KB
/
yugabyte-db.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
name: YUGABYTE_DEPLOYMENT
on:
workflow_dispatch:
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Set up SSH
uses: webfactory/[email protected]
with:
ssh-private-key: ${{ secrets.SSH_PRIVATE_KEY }}
- name: Add Host to Known Hosts
run: |
ssh-keyscan -H ${{ secrets.HOST }} >> ~/.ssh/known_hosts
- name: Deploy yugabyte db
run: |
ssh -o StrictHostKeyChecking=no ${{ secrets.USER }}@${{ secrets.HOST }} << 'EOF'
# Deploy yugabyte container with the ACL file
docker pull yugabytedb/yugabyte:latest
sudo docker stop yugabyte-db || true && sudo docker rm yugabyte-db || true &&
docker run -d --name yugabyte-db \
-p7000:7000 -p9000:9000 -p15433:15433 -p5433:5433 -p9042:9042 \
-v ~/yb_data:/home/yugabyte/yb_data \
-e YB_PASSWORD=${{vars.YUGABYTE_PASSWORD}} \
yugabytedb/yugabyte:latest bin/yugabyted start \
--base_dir=/home/yugabyte/yb_data \
--background=false --ysql_enable_auth=true
EOF