Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

deploy-release.yml 1.5 KB

You have to be logged in to leave a comment. Sign In
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
  1. name: Deploy to production
  2. on:
  3. # run this workflow manually from the Actions tab
  4. workflow_dispatch:
  5. jobs:
  6. update-env:
  7. runs-on: ubuntu-latest
  8. timeout-minutes: 10
  9. steps:
  10. - uses: actions/checkout@v3
  11. - uses: actions/setup-node@v3
  12. with:
  13. node-version: "20"
  14. cache: "npm"
  15. - run: npm install ci
  16. - name: "Update DOTENV_LOCAL in prod"
  17. env:
  18. HF_TOKEN: ${{ secrets.HF_TOKEN }}
  19. SERPER_API_KEY: ${{ secrets.SERPER_API_KEY }}
  20. OPENID_CONFIG: ${{ secrets.OPENID_CONFIG }}
  21. MONGODB_URL: ${{ secrets.MONGODB_URL }}
  22. HF_DEPLOYMENT_TOKEN: ${{ secrets.HF_DEPLOYMENT_TOKEN }}
  23. WEBHOOK_URL_REPORT_ASSISTANT: ${{ secrets.WEBHOOK_URL_REPORT_ASSISTANT }}
  24. ADMIN_API_SECRET: ${{ secrets.ADMIN_API_SECRET }}
  25. USAGE_LIMITS: ${{ secrets.USAGE_LIMITS }}
  26. MESSAGES_BEFORE_LOGIN: ${{ secrets.MESSAGES_BEFORE_LOGIN }}
  27. run: npm run updateProdEnv
  28. sync-to-hub:
  29. runs-on: ubuntu-latest
  30. steps:
  31. - name: Check large files
  32. uses: ActionsDesk/lfs-warning@v2.0
  33. with:
  34. filesizelimit: 10485760 # this is 10MB so we can sync to HF Spaces
  35. - uses: actions/checkout@v3
  36. with:
  37. fetch-depth: 0
  38. lfs: true
  39. - name: Push to hub
  40. env:
  41. HF_DEPLOYMENT_TOKEN: ${{ secrets.HF_DEPLOYMENT_TOKEN }}
  42. run: git push https://nsarrazin:$HF_DEPLOYMENT_TOKEN@huggingface.co/spaces/huggingchat/chat-ui main
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...