entitlements-github-plugin 1.2.9 → 1.2.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/lib/entitlements/service/github.rb +6 -1
- data/lib/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 383db00707ac5b36043a36a75bcb2cbae1395532759725ca9dea32e122391116
|
|
4
|
+
data.tar.gz: a82b954cdcb8bc972856fe608134341a777ff2a182ca8b811b322c7aa8b92cf3
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: c17712815928a364ef74a95b4f6c165d9a4f82d248693dd6f34e691ce529ba62cae587ff677e2888f2675ab8fac4986c1f55ed6e0e865114ba62d5c5acf8ec6b
|
|
7
|
+
data.tar.gz: e438198f088d118d6c88497e8b0388de26f2871222d769b0b11cb5fec51a199d9a7d9e67cd607def5e6ae569bde67d401a11378a959831e9da1b805b9ffcfe9d
|
|
@@ -204,13 +204,18 @@ module Entitlements
|
|
|
204
204
|
end
|
|
205
205
|
|
|
206
206
|
# Use GraphQL in GitHub Actions, where entitlements-caches can answer it, and REST elsewhere.
|
|
207
|
+
# .ghe.com orgs are not served by entitlements-caches, so they always use REST.
|
|
207
208
|
#
|
|
208
209
|
# Takes no parameters.
|
|
209
210
|
#
|
|
210
211
|
# Returns Hash of { "username" => "ROLE" } where "ROLE" is from GraphQL Enum.
|
|
211
212
|
Contract C::None => C::HashOf[String => String]
|
|
212
213
|
def members_and_roles_from_api
|
|
213
|
-
ENV["GITHUB_RUN_ID"] ?
|
|
214
|
+
if ENV["GITHUB_RUN_ID"] && !graphql_uri.host.end_with?(".ghe.com")
|
|
215
|
+
members_and_roles_from_graphql
|
|
216
|
+
else
|
|
217
|
+
members_and_roles_from_rest
|
|
218
|
+
end
|
|
214
219
|
end
|
|
215
220
|
|
|
216
221
|
# Query GraphQL API to get a list of members and their roles.
|
data/lib/version.rb
CHANGED