Обновить .gitea/workflows/test-runner.yml

This commit is contained in:
danyadjan 2025-03-20 14:54:16 +03:00
parent 02b60ca36e
commit 00b05f9312

View File

@ -7,29 +7,24 @@ on:
jobs:
deploy:
runs-on: kyc_runner
runs-on:kyc_runner
steps:
- name: Set up workspace directory
run: mkdir -p /opt/myapp
- name: Checkout repository
uses: actions/checkout@v4
with:
path: /opt/myapp
path: myapp
- name: Verify Node.js installation
- name: Print working directory
run: pwd && ls -lah
- name: Move app to target directory
run: |
if ! command -v node &> /dev/null; then
echo "Node.js not found, installing..."
sudo apt update && sudo apt install -y nodejs
fi
echo "Using Node.js version: $(node -v)"
sudo rm -rf /opt/myapp # Remove old deployment
sudo mv ${{ github.workspace }}/myapp /opt/myapp
sudo chown -R $USER:$USER /opt/myapp
- name: List repository files
run: ls -lah /opt/myapp
- name: Start the application with Docker Compose
- name: Start application with Docker Compose
run: |
cd /opt/myapp
docker-compose up --build -d