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.

103 lines
3.3 KiB

3 years ago
3 years ago
2 years ago
2 years ago
2 years ago
3 years ago
7 months ago
7 months ago
3 years ago
3 years ago
3 years ago
1 year ago
3 years ago
2 years ago
2 years ago
2 years ago
2 years ago
3 years ago
3 years ago
  1. name: Ubuntu
  2. on:
  3. push:
  4. branches:
  5. - '*'
  6. paths:
  7. - '*.sh'
  8. - '.github/workflows/Ubuntu.yml'
  9. pull_request:
  10. branches:
  11. - dev
  12. paths:
  13. - '*.sh'
  14. - '.github/workflows/Ubuntu.yml'
  15. concurrency:
  16. group: ${{ github.workflow }}-${{ github.ref }}
  17. cancel-in-progress: true
  18. jobs:
  19. Ubuntu:
  20. strategy:
  21. matrix:
  22. include:
  23. - TEST_ACME_Server: "LetsEncrypt.org_test"
  24. CA_ECDSA: ""
  25. CA: ""
  26. CA_EMAIL: ""
  27. TEST_PREFERRED_CHAIN: (STAGING)
  28. - TEST_ACME_Server: "LetsEncrypt.org_test"
  29. CA_ECDSA: ""
  30. CA: ""
  31. CA_EMAIL: ""
  32. TEST_PREFERRED_CHAIN: (STAGING)
  33. ACME_USE_WGET: 1
  34. - TEST_ACME_Server: "ZeroSSL.com"
  35. CA_ECDSA: "ZeroSSL ECC Domain Secure Site CA"
  36. CA: "ZeroSSL RSA Domain Secure Site CA"
  37. CA_EMAIL: "githubtest@acme.sh"
  38. TEST_PREFERRED_CHAIN: ""
  39. - TEST_ACME_Server: "https://localhost:9000/acme/acme/directory"
  40. CA_ECDSA: "Smallstep Intermediate CA"
  41. CA: "Smallstep Intermediate CA"
  42. CA_EMAIL: ""
  43. TEST_PREFERRED_CHAIN: ""
  44. NO_REVOKE: 1
  45. - TEST_ACME_Server: "https://localhost:9000/acme/acme/directory"
  46. CA_ECDSA: "Smallstep Intermediate CA"
  47. CA: "Smallstep Intermediate CA"
  48. CA_EMAIL: ""
  49. TEST_PREFERRED_CHAIN: ""
  50. NO_REVOKE: 1
  51. TEST_IPCERT: 1
  52. TestingDomain: "172.17.0.1"
  53. runs-on: ubuntu-latest
  54. env:
  55. TEST_LOCAL: 1
  56. TEST_ACME_Server: ${{ matrix.TEST_ACME_Server }}
  57. CA_ECDSA: ${{ matrix.CA_ECDSA }}
  58. CA: ${{ matrix.CA }}
  59. CA_EMAIL: ${{ matrix.CA_EMAIL }}
  60. NO_ECC_384: ${{ matrix.NO_ECC_384 }}
  61. TEST_PREFERRED_CHAIN: ${{ matrix.TEST_PREFERRED_CHAIN }}
  62. NO_REVOKE: ${{ matrix.NO_REVOKE }}
  63. TEST_IPCERT: ${{ matrix.TEST_IPCERT }}
  64. TestingDomain: ${{ matrix.TestingDomain }}
  65. ACME_USE_WGET: ${{ matrix.ACME_USE_WGET }}
  66. steps:
  67. - uses: actions/checkout@v4
  68. - name: Install tools
  69. run: sudo apt-get install -y socat wget
  70. - name: Start StepCA
  71. if: ${{ matrix.TEST_ACME_Server=='https://localhost:9000/acme/acme/directory' }}
  72. run: |
  73. docker run --rm -d \
  74. -p 9000:9000 \
  75. -e "DOCKER_STEPCA_INIT_NAME=Smallstep" \
  76. -e "DOCKER_STEPCA_INIT_DNS_NAMES=localhost,$(hostname -f)" \
  77. -e "DOCKER_STEPCA_INIT_REMOTE_MANAGEMENT=true" \
  78. -e "DOCKER_STEPCA_INIT_PASSWORD=test" \
  79. --name stepca \
  80. smallstep/step-ca:0.23.1
  81. sleep 5
  82. docker exec stepca bash -c "echo test >test" \
  83. && docker exec stepca step ca provisioner add acme --type ACME --admin-subject step --admin-password-file=/home/step/test \
  84. && docker exec stepca kill -1 1 \
  85. && docker exec stepca cat /home/step/certs/root_ca.crt | sudo bash -c "cat - >>/etc/ssl/certs/ca-certificates.crt"
  86. - name: Clone acmetest
  87. run: |
  88. cd .. \
  89. && git clone --depth=1 https://github.com/acmesh-official/acmetest.git \
  90. && cp -r acme.sh acmetest/
  91. - name: Run acmetest
  92. run: |
  93. cd ../acmetest \
  94. && sudo --preserve-env ./letest.sh