SmartParks/.gitea/workflows/dev.yml
Workflow config file is invalid. Please check your config file: yaml: line 10: could not find expected ':'

54 lines
1.6 KiB
YAML

name: Gitea Actions Demo
run-name: ${{ gitea.actor }} is testing out Gitea Actions 🚀
on: [push]
jobs:
Explore-Gitea-Actions:
runs-on: ubuntu-latest
steps:
- name: Checkout code
uses:http://47.109.37.87:3000/bichangxiong/checkout@v4 # 使用 Gitea 镜像
with:
fetch-depth: 1 # 只拉取最新一次提交
# - name: Checkout code
# uses: actions/checkout@v4 # 拉取代码到工作目录
- name: Set up JDK 17
uses: actions/setup-java@v3
with:
java-version: '17'
distribution: 'temurin'
cache: maven
- name: Set up Maven
uses: stCarolas/setup-maven@v5
with:
maven-version: 3.8.2
- name: List files in the repository
run: |
ls ${{ gitea.workspace }}
- name: Install dependencies
run: mvn clean package -DskipTests
- name: copy file via ssh password
uses: appleboy/scp-action@v0.1.7
with:
host: 192.168.1.3
username: root
password: by@2025!
port: 22
source: "SmartParks/ruoyi-modules/Property/target/Property.jar,SmartParks/ruoyi-modules/Property/docker-compose.yml,SmartParks/ruoyi-modules/Property/Dockerfile"
target: "/project/runner/plus/"
- name: Deploy to server via SSH
uses: appleboy/ssh-action@v0.1.7
with:
host: 192.168.1.220
username: root
password: by@2025!
port: 22
script: |
cd /project/runner/plus/
docker-compose up -d --force-recreate
- run: echo "🍏 This job's status is ${{ job.status }}."