You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

77 lines
2.4 KiB

4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
4 years ago
  1. name: LetsEncrypt
  2. on:
  3. push:
  4. branches:
  5. - '*'
  6. paths:
  7. - '**.sh'
  8. pull_request:
  9. branches:
  10. - dev
  11. paths:
  12. - '**.sh'
  13. jobs:
  14. Ubuntu:
  15. runs-on: ubuntu-latest
  16. if: "contains(secrets.NGROK_TOKEN, '-')"
  17. env:
  18. NGROK_TOKEN : ${{ secrets.NGROK_TOKEN }}
  19. TEST_LOCAL: 1
  20. steps:
  21. - uses: actions/checkout@v2
  22. - name: Install tools
  23. run: sudo apt-get install -y socat
  24. - name: Clone acmetest
  25. run: cd .. && git clone https://github.com/acmesh-official/acmetest.git && cp -r acme.sh acmetest/
  26. - name: Run acmetest
  27. run: cd ../acmetest && sudo TEST_LOCAL="$TEST_LOCAL" NGROK_TOKEN="$NGROK_TOKEN" ./letest.sh
  28. MacOS:
  29. runs-on: macos-latest
  30. if: "contains(secrets.NGROK_TOKEN, '-')"
  31. needs: Ubuntu
  32. env:
  33. NGROK_TOKEN : ${{ secrets.NGROK_TOKEN }}
  34. TEST_LOCAL: 1
  35. steps:
  36. - uses: actions/checkout@v2
  37. - name: Install tools
  38. run: brew update && brew install socat;
  39. - name: Clone acmetest
  40. run: cd .. && git clone https://github.com/acmesh-official/acmetest.git && cp -r acme.sh acmetest/
  41. - name: Run acmetest
  42. run: cd ../acmetest && sudo TEST_LOCAL="$TEST_LOCAL" NGROK_TOKEN="$NGROK_TOKEN" ./letest.sh
  43. Windows:
  44. runs-on: windows-latest
  45. if: "contains(secrets.NGROK_TOKEN, '-')"
  46. needs: MacOS
  47. env:
  48. NGROK_TOKEN : ${{ secrets.NGROK_TOKEN }}
  49. TEST_LOCAL: 1
  50. #The 80 port is used by Windows server, we have to use a custom port, ngrok will also use this port.
  51. Le_HTTPPort: 8888
  52. steps:
  53. - uses: actions/checkout@v2
  54. - name: Install cygwin base packages with chocolatey
  55. run: |
  56. choco config get cacheLocation
  57. choco install --no-progress cygwin
  58. shell: cmd
  59. - name: Install cygwin additional packages
  60. run: |
  61. C:\tools\cygwin\cygwinsetup.exe -qgnNdO -R C:/tools/cygwin -s http://mirrors.kernel.org/sourceware/cygwin/ -P socat,curl,cron,unzip,git
  62. shell: cmd
  63. - name: Set ENV
  64. run: |
  65. echo '::set-env name=PATH::C:\tools\cygwin\bin;C:\tools\cygwin\usr\bin'
  66. - name: Clone acmetest
  67. shell: cmd
  68. run: cd .. && git clone https://github.com/acmesh-official/acmetest.git && cp -r acme.sh acmetest/ && sed -i 's/\r//g' acmetest/acme.sh/acme.sh
  69. - name: Run acmetest
  70. shell: cmd
  71. run: cd ../acmetest && bash.exe -c ./letest.sh