mirror of
https://github.com/livebook-dev/livebook.git
synced 2025-11-09 21:51:42 +08:00
Revert some changes
This commit is contained in:
parent
f3f86e904f
commit
fe2dda96f8
5 changed files with 5 additions and 10 deletions
|
|
@ -93,7 +93,7 @@ defmodule Livebook.FileSystem.S3 do
|
|||
If the credentials are not specified by the file system, they are
|
||||
fetched from environment variables or AWS instance if applicable.
|
||||
"""
|
||||
@spec credentials(t()) :: credentials()
|
||||
@spec credentials(S3.t()) :: S3.credentials()
|
||||
def credentials(%__MODULE__{} = file_system) do
|
||||
case {file_system.access_key_id, file_system.secret_access_key} do
|
||||
{nil, nil} ->
|
||||
|
|
|
|||
|
|
@ -230,7 +230,7 @@ defmodule Livebook.Teams do
|
|||
@doc """
|
||||
Gets a list of environment variables for a given Hub.
|
||||
"""
|
||||
@spec get_environment_variables(Team.t()) :: list(Teams.EnvironmentVariable.t())
|
||||
@spec get_environment_variables(Team.t()) :: list(Teams.Agent.t())
|
||||
def get_environment_variables(team) do
|
||||
TeamClient.get_environment_variables(team.id)
|
||||
end
|
||||
|
|
|
|||
|
|
@ -87,7 +87,6 @@ defmodule Livebook.ZTA.LivebookTeams do
|
|||
|> put_status(:bad_request)
|
||||
|> delete_session(:teams_error)
|
||||
|> put_view(LivebookWeb.ErrorHTML)
|
||||
|> put_root_layout(false)
|
||||
|> render("400.html", %{status: 400})
|
||||
|> halt(), nil}
|
||||
|
||||
|
|
@ -96,7 +95,6 @@ defmodule Livebook.ZTA.LivebookTeams do
|
|||
|> put_status(:forbidden)
|
||||
|> delete_session(:teams_failed_reason)
|
||||
|> put_view(LivebookWeb.ErrorHTML)
|
||||
|> put_root_layout(false)
|
||||
|> render("error.html", %{
|
||||
status: 403,
|
||||
details: "Failed to authenticate with Livebook Teams: #{reason}"
|
||||
|
|
|
|||
|
|
@ -21,7 +21,6 @@ defmodule LivebookWeb.Hub.Edit.TeamComponent do
|
|||
secret_name = assigns.params["secret_name"]
|
||||
file_system_id = assigns.params["file_system_id"]
|
||||
default? = default_hub?(assigns.hub)
|
||||
connection_status = Provider.connection_status(assigns.hub)
|
||||
|
||||
secret_value =
|
||||
if assigns.live_action == :edit_secret do
|
||||
|
|
@ -51,8 +50,7 @@ defmodule LivebookWeb.Hub.Edit.TeamComponent do
|
|||
secret_name: secret_name,
|
||||
secret_value: secret_value,
|
||||
hub_metadata: Provider.to_metadata(assigns.hub),
|
||||
default?: default?,
|
||||
connection_status: connection_status
|
||||
default?: default?
|
||||
)
|
||||
|> assign_form(changeset)}
|
||||
end
|
||||
|
|
@ -61,8 +59,8 @@ defmodule LivebookWeb.Hub.Edit.TeamComponent do
|
|||
def render(assigns) do
|
||||
~H"""
|
||||
<div>
|
||||
<LayoutComponents.topbar :if={@connection_status} variant="warning">
|
||||
{@connection_status}
|
||||
<LayoutComponents.topbar :if={Provider.connection_status(@hub)} variant="warning">
|
||||
{Provider.connection_status(@hub)}
|
||||
</LayoutComponents.topbar>
|
||||
|
||||
<LayoutComponents.topbar :if={@hub.billing_status.type == :trialing} variant="warning">
|
||||
|
|
|
|||
|
|
@ -53,7 +53,6 @@ defmodule LivebookWeb.UserPlug do
|
|||
conn
|
||||
|> put_status(:forbidden)
|
||||
|> put_view(LivebookWeb.ErrorHTML)
|
||||
|> put_root_layout(false)
|
||||
|> render("403.html", %{status: 403})
|
||||
|> halt()
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue