storage.yml 6.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148
  1. name: storage
  2. on:
  3. pull_request:
  4. paths:
  5. - 'FirebaseStorage**'
  6. - 'Interop/Auth/Public/*.h'
  7. - '.github/workflows/storage.yml'
  8. - 'scripts/**'
  9. # Rebuild on Ruby infrastructure changes.
  10. - 'Gemfile'
  11. schedule:
  12. # Run every day at 11pm (PST) - cron uses UTC times
  13. - cron: '0 7 * * *'
  14. jobs:
  15. storage:
  16. # Don't run on private repo unless it is a PR.
  17. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  18. env:
  19. plist_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  20. runs-on: macos-latest
  21. strategy:
  22. matrix:
  23. pod: [Storage, StorageSwift]
  24. steps:
  25. - uses: actions/checkout@v2
  26. - name: Setup Bundler
  27. run: scripts/setup_bundler.sh
  28. - name: Install Secret GoogleService-Info.plist
  29. run: scripts/decrypt_gha_secret.sh scripts/gha-encrypted/storage-db-plist.gpg \
  30. FirebaseStorage/Tests/Integration/Resources/GoogleService-Info.plist "$plist_secret"
  31. - name: Install Credentials.h
  32. run: scripts/decrypt_gha_secret.sh scripts/gha-encrypted/Storage/Credentials.h.gpg \
  33. FirebaseStorage/Tests/Integration/Credentials.h "$plist_secret"
  34. - name: Install Credentials.swift
  35. run: |
  36. scripts/decrypt_gha_secret.sh scripts/gha-encrypted/Storage/Credentials.swift.gpg \
  37. FirebaseStorage/Tests/SwiftIntegration/Credentials.swift "$plist_secret"
  38. cp FirebaseStorage/Tests/SwiftIntegration/Credentials.swift FirebaseStorageSwift/Tests/Integration/
  39. - name: BuildAndTest # can be replaced with pod lib lint with CocoaPods 1.10
  40. run: ([ -z $plist_secret ] || scripts/third_party/travis/retry.sh scripts/build.sh ${{ matrix.pod }} all)
  41. spm:
  42. # Don't run on private repo unless it is a PR.
  43. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  44. runs-on: macOS-latest
  45. steps:
  46. - uses: actions/checkout@v2
  47. - name: Xcode 12
  48. run: sudo xcode-select -s /Applications/Xcode_12.app/Contents/Developer
  49. - name: Initialize xcodebuild
  50. run: xcodebuild -list
  51. - name: iOS Unit Tests
  52. run: scripts/third_party/travis/retry.sh ./scripts/build.sh StorageUnit iOS spm
  53. - name: Swift Build
  54. run: scripts/third_party/travis/retry.sh ./scripts/build.sh FirebaseStorageSwift-Beta iOS spmbuildonly
  55. spm-cron:
  56. # Don't run on private repo.
  57. if: github.event_name == 'schedule' && github.repository == 'Firebase/firebase-ios-sdk'
  58. runs-on: macOS-latest
  59. strategy:
  60. matrix:
  61. target: [tvOS, macOS, catalyst]
  62. steps:
  63. - uses: actions/checkout@v2
  64. - name: Xcode 12
  65. run: sudo xcode-select -s /Applications/Xcode_12.app/Contents/Developer
  66. - name: Initialize xcodebuild
  67. run: xcodebuild -list
  68. - name: Unit Tests
  69. run: scripts/third_party/travis/retry.sh ./scripts/build.sh StorageUnit ${{ matrix.target }} spm
  70. - name: Swift Build
  71. run: scripts/third_party/travis/retry.sh ./scripts/build.sh FirebaseStorageSwift-Beta ${{ matrix.target }} spmbuildonly
  72. catalyst:
  73. # Don't run on private repo unless it is a PR.
  74. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  75. runs-on: macOS-latest
  76. steps:
  77. - uses: actions/checkout@v2
  78. - name: Setup Bundler
  79. run: scripts/setup_bundler.sh
  80. - name: Setup project and Build for Catalyst
  81. run: scripts/test_catalyst.sh FirebaseStorage test FirebaseStorage-Unit-unit
  82. quickstart:
  83. # Don't run on private repo unless it is a PR.
  84. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  85. env:
  86. plist_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  87. signin_secret: ${{ secrets.GHASecretsGPGPassphrase1 }}
  88. runs-on: macOS-latest
  89. steps:
  90. - uses: actions/checkout@v2
  91. - name: Setup quickstart
  92. run: scripts/setup_quickstart.sh storage
  93. - name: Install Secret GoogleService-Info.plist
  94. run: scripts/decrypt_gha_secret.sh scripts/gha-encrypted/qs-storage.plist.gpg \
  95. quickstart-ios/storage/GoogleService-Info.plist "$plist_secret"
  96. - name: Install Secret FIREGSignInInfo.h
  97. run: scripts/decrypt_gha_secret.sh scripts/gha-encrypted/FIREGSignInInfo.h.gpg \
  98. quickstart-ios/TestUtils/FIREGSignInInfo.h "$signin_secret"
  99. - name: Test objc quickstart
  100. run: ([ -z $plist_secret ] || scripts/third_party/travis/retry.sh scripts/test_quickstart.sh Storage)
  101. - name: Test swift quickstart
  102. run: ([ -z $plist_secret ] || scripts/third_party/travis/retry.sh scripts/test_quickstart.sh Storage swift)
  103. pod-lib-lint:
  104. # Don't run on private repo unless it is a PR.
  105. if: (github.repository == 'Firebase/firebase-ios-sdk' && github.event_name == 'schedule') || github.event_name == 'pull_request'
  106. runs-on: macOS-latest
  107. strategy:
  108. matrix:
  109. # watchos is disabled since pod lib lint cannot handle test Auth dep even if the dep is only
  110. # specified for the other three platforms.
  111. target: [ios, tvos, macos]
  112. steps:
  113. - uses: actions/checkout@v2
  114. - name: Setup Bundler
  115. run: scripts/setup_bundler.sh
  116. - name: Build and test
  117. run: |
  118. scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseStorage.podspec --skip-tests --platforms=${{ matrix.target }}
  119. scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseStorageSwift.podspec --skip-tests --platforms=${{ matrix.target }}
  120. storage-cron-only:
  121. # Don't run on private repo.
  122. if: github.event_name == 'schedule' && github.repository == 'Firebase/firebase-ios-sdk'
  123. runs-on: macos-latest
  124. strategy:
  125. matrix:
  126. target: [ios, tvos, macos]
  127. flags: [
  128. '--skip-tests --use-static-frameworks',
  129. '--skip-tests --use-libraries'
  130. ]
  131. needs: pod-lib-lint
  132. steps:
  133. - uses: actions/checkout@v2
  134. - name: Setup Bundler
  135. run: scripts/setup_bundler.sh
  136. - name: PodLibLint Storage Cron
  137. run: |
  138. scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseStorage.podspec --platforms=${{ matrix.target }} ${{ matrix.flags }}
  139. scripts/third_party/travis/retry.sh scripts/pod_lib_lint.rb FirebaseStorage.podspec --platforms=${{ matrix.target }} ${{ matrix.flags }}