theforeman/foreman-docker

View on GitHub
app/views/compute_resources/form/_docker.html.erb

Summary

Maintainability
Test Coverage
<%= text_f f, :url, :size => "col-md-8", :help_block => _("e.g. https://docker.example.com:4243 or unix:///var/run/docker.sock") %>
<%= text_f f, :user %>
<%= password_f f, :password %>
<%= text_f f, :email %>

<% authenticated = f.object.authenticate! rescue false %>
<%= link_to_function _("Test Connection"), "testConnection(this)",
                    :class => "btn + #{authenticated ? "btn-success" : "btn-default"}",
                    :'data-url' => test_connection_compute_resources_path %>

<%= spinner('', :id => 'test_connection_indicator', :class => 'hide') %>