Skip to content

Commit b66b635

Browse files
committed
fix(front): Feature flag user git provider connection management
1 parent 4108ee5 commit b66b635

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

front/lib/front_web/templates/account/show.html.eex

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@
4141
<span class="red">Not Connected</span>
4242
·
4343
<span><a href="https://github.com/<%= @user.github_login %>" target="_blank">@<%= @user.github_login %></a></span>
44-
<%= if Front.saas?() do %>
44+
<%= if FeatureProvider.feature_enabled?(:user_repos_access, param: org_id) do %>
4545
<div>
4646
<%= link "Grant public access…", to: account_path(@conn, :update_repo_scope, "github", [access_level: :public]), method: :post %>
4747
<%= link "Grant private access…", to: account_path(@conn, :update_repo_scope, "github", [access_level: :private]), method: :post %>
@@ -53,7 +53,7 @@
5353
<span class="gray">email only</span>
5454
·
5555
<span><a href="https://github.com/<%= @user.github_login %>" target="_blank">@<%= @user.github_login %></a></span>
56-
<%= if Front.saas?() do %>
56+
<%= if FeatureProvider.feature_enabled?(:user_repos_access, param: org_id) do %>
5757
<div>
5858
<%= link "Grant public access…", to: account_path(@conn, :update_repo_scope, "github", [access_level: :public]), method: :post %>
5959
<%= link "Grant private access…", to: account_path(@conn, :update_repo_scope, "github", [access_level: :private]), method: :post %>
@@ -65,7 +65,7 @@
6565
<span class="gray">public repositories</span>
6666
·
6767
<span><a href="https://github.com/<%= @user.github_login %>" target="_blank">@<%= @user.github_login %></a></span>
68-
<%= if Front.saas?() do %>
68+
<%= if FeatureProvider.feature_enabled?(:user_repos_access, param: org_id) do %>
6969
<div>
7070
<%= link "Grant private access…", to: account_path(@conn, :update_repo_scope, "github", [access_level: :private]), method: :post %>
7171
</div>

helm-chart/templates/configmaps/features.yaml

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,8 @@ data:
3636
enabled: false
3737
bitbucket_user_provider:
3838
enabled: false
39+
user_repos_access:
40+
enabled: true
3941
deployment_targets:
4042
enabled: false
4143
expose_cloud_agent_types:
@@ -152,6 +154,8 @@ data:
152154
enabled: false
153155
bitbucket_user_provider:
154156
enabled: false
157+
user_repos_access:
158+
enabled: true
155159
deployment_targets:
156160
enabled: true
157161
expose_cloud_agent_types:

0 commit comments

Comments
 (0)