build-eslint.yml 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142
  1. name: Musare Build and ESLint
  2. on: [ push, pull_request, workflow_dispatch ]
  3. env:
  4. COMPOSE_PROJECT_NAME: musare
  5. RESTART_POLICY: unless-stopped
  6. CONTAINER_MODE: prod
  7. BACKEND_HOST: 127.0.0.1
  8. BACKEND_PORT: 8080
  9. FRONTEND_HOST: 127.0.0.1
  10. FRONTEND_PORT: 80
  11. FRONTEND_MODE: dev
  12. MONGO_HOST: 127.0.0.1
  13. MONGO_PORT: 27017
  14. MONGO_ROOT_PASSWORD: PASSWORD_HERE
  15. MONGO_USER_USERNAME: musare
  16. MONGO_USER_PASSWORD: OTHER_PASSWORD_HERE
  17. MONGO_DATA_LOCATION: .db
  18. MONGO_VERSION: 5.0
  19. REDIS_HOST: 127.0.0.1
  20. REDIS_PORT: 6379
  21. REDIS_PASSWORD: PASSWORD
  22. REDIS_DATA_LOCATION: .redis
  23. jobs:
  24. build-eslint:
  25. runs-on: ubuntu-latest
  26. steps:
  27. - uses: actions/checkout@v2
  28. - name: Build Musare
  29. run: |
  30. cp .env.example .env
  31. cp backend/config/template.json backend/config/default.json
  32. cp frontend/dist/config/template.json frontend/dist/config/default.json
  33. ./musare.sh build
  34. - name: Start Musare
  35. run: ./musare.sh start
  36. - name: ESlint Backend
  37. run: ./musare.sh eslint backend
  38. - name: ESLint Frontend
  39. run: ./musare.sh eslint frontend