chore: map legacy Claude co-author identity #91
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: CI - 1Shell 4.1 | |
| on: | |
| push: | |
| branches: [main, dev] | |
| pull_request: | |
| branches: [main] | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| strategy: | |
| matrix: | |
| node-version: [18, 20] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup Node.js ${{ matrix.node-version }} | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| cache: npm | |
| - name: Install dependencies | |
| run: npm ci | |
| - name: Run tests | |
| run: npm test | |
| env: | |
| APP_SECRET: ci-test-secret-key-for-testing | |
| APP_LOGIN_PASSWORD: ci-test-password | |
| - name: Install frontend dependencies | |
| run: npm --prefix frontend ci | |
| - name: Build frontend | |
| run: npm --prefix frontend run build | |
| - name: Setup Go | |
| uses: actions/setup-go@v5 | |
| with: | |
| go-version: '1.22.x' | |
| - name: Test probe agent | |
| working-directory: agent | |
| run: go test ./... | |
| docker: | |
| runs-on: ubuntu-latest | |
| needs: test | |
| if: github.ref == 'refs/heads/main' | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Build Docker image | |
| run: docker build -t 1shell:test . | |
| - name: Verify container starts | |
| run: | | |
| docker run -d --name 1shell-test \ | |
| -e APP_SECRET=ci-test-secret \ | |
| -e APP_LOGIN_PASSWORD=ci-test-pw \ | |
| -p 3301:3301 \ | |
| 1shell:test | |
| for i in {1..30}; do | |
| if curl -sf http://localhost:3301/api/health | grep -q '"status":"ok"'; then | |
| docker stop 1shell-test | |
| exit 0 | |
| fi | |
| sleep 1 | |
| done | |
| docker ps -a | |
| docker logs 1shell-test | |
| docker stop 1shell-test || true | |
| exit 1 |