smb-kerberos.yml 1.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556
  1. name: Samba Kerberos SSO
  2. on:
  3. pull_request:
  4. paths:
  5. - 'apps/files_external/**'
  6. - '.github/workflows/smb-kerberos.yml'
  7. concurrency:
  8. group: smb-kerberos-${{ github.head_ref || github.run_id }}
  9. cancel-in-progress: true
  10. jobs:
  11. smb-kerberos-tests:
  12. runs-on: ubuntu-22.04
  13. if: ${{ github.repository_owner != 'nextcloud-gmbh' }}
  14. name: smb-kerberos-sso
  15. steps:
  16. - name: Checkout server
  17. uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
  18. with:
  19. submodules: true
  20. - name: Checkout user_saml
  21. uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
  22. with:
  23. repository: nextcloud/user_saml
  24. path: apps/user_saml
  25. ref: stable-5.2
  26. - name: Pull images
  27. run: |
  28. docker pull ghcr.io/icewind1991/samba-krb-test-dc
  29. docker pull ghcr.io/icewind1991/samba-krb-test-apache
  30. docker pull ghcr.io/icewind1991/samba-krb-test-client
  31. docker tag ghcr.io/icewind1991/samba-krb-test-dc icewind1991/samba-krb-test-dc
  32. docker tag ghcr.io/icewind1991/samba-krb-test-apache icewind1991/samba-krb-test-apache
  33. docker tag ghcr.io/icewind1991/samba-krb-test-client icewind1991/samba-krb-test-client
  34. - name: Setup AD-DC
  35. run: |
  36. DC_IP=$(apps/files_external/tests/sso-setup/start-dc.sh)
  37. sleep 1
  38. apps/files_external/tests/sso-setup/start-apache.sh $DC_IP $PWD
  39. echo "DC_IP=$DC_IP" >> $GITHUB_ENV
  40. - name: Set up Nextcloud
  41. run: |
  42. apps/files_external/tests/sso-setup/setup-sso-nc.sh
  43. - name: Test SSO
  44. run: |
  45. apps/files_external/tests/sso-setup/test-sso-smb.sh ${{ env.DC_IP }}
  46. - name: Show logs
  47. if: failure()
  48. run: |
  49. FILEPATH=$(docker exec --user 33 apache ./occ log:file | grep "Log file:" | cut -d' ' -f3)
  50. echo "$FILEPATH:"
  51. docker exec --user 33 apache cat $FILEPATH