version: v0
kind: Pipeline
name: music
services: []
steps:
  - name: Install Dependencies
    image: patrcloud/cli:latest
    commands:
      - npm install
    next: Build Code
  - name: Build Code
    image: patrcloud/cli:latest
    commands:
      - npm run build
    next: Publish on Patr
  - name: Publish on Patr
    image: patrcloud/cli:latest
    commands:
      - patr login -u "$USERNAME" -p "$PASSWORD"
      - patr workspace switch "$WORKSPACE_ID"
      - patr site upload --site ./public "music" --msg "$PATR_CI_COMMIT_MESSAGE"
    environment:
      USERNAME: agczsz
      PASSWORD:
        from_secret: PATR_PASSWORD
      WORKSPACE_ID: 5295d858688749c88a39100195147b85
