Administration
==============

Admin UI
--------

An Anaconda Enterprise Notebooks account can be enabled to have
Administrator privileges. An account that has Administrator privileges
will have two options (Admin & Users) in the upper bar of the profile
page not found on a general account. The Admin option allows you access
to additional Anaconda Enterprise Notebooks settings and reports. The
User option allows you to see all the active users and navigate to their
profile screen.

|image0|

Staff
~~~~~

Daily Report
^^^^^^^^^^^^

The Daily Report tab provides reports of the number of users and
projects. For new users (if Open Registration is allowed, see also :ref:`Site
Admin - Accounts <aen-index-site-admin-accounts>`) in the selected time frame the report
shows the corresponding usernames and emails. The report also shows a
list of actions (projects created, projects updated, user
authentications, added users, and so on) that occurred in Anaconda
Enterprise Notebooks over the selected time frame. You can see this
information for *Today*, *Yesterday*, *This Week*, and *This Month*.

|image1|

Password Reset
^^^^^^^^^^^^^^

Enter the username of the user who needs a new password and click the
*Generate URL* button. This generates a link that can be sent to the
user to reset their password, or the administrator can use that link to
create a new password for that user.

|image2|

Notification
^^^^^^^^^^^^

Notifications are off by default. You can turn on email notifications
using Amazon Simple Email Service, or by entering SMTP Email Server
settings.

|image3|

Exceptions
^^^^^^^^^^

The Exception tab lists any errors that were raised while Anaconda
Enterprise Notebooks is running. A red dot will appear next to *Admin*
in the top navigation bar. To remove the red button from this page go to
the *Exceptions* tab and click the *Mark all as read* button.

|image4|

Click on a particular exception to find out more details on what caused
it.

|image5|

Site Admin
~~~~~~~~~~

General
^^^^^^^

This tab is where you can change the settings for your AE Notebook
installation. Includes the main URL where the site will be accessed, the
static URL where the js can be accessed, the default project access
(public or private), and the account type (cloud or LDAP).

The config files can also be changed.

|image6|

If you make any changes, be sure to click the green *Update* button, so
the changes will be applied.

.. _aen-index-site-admin-accounts:

Accounts
^^^^^^^^

The Accounts tab lets you turn on or off Open Registration. When Open
Registration is checked new users can sign up. You must hit the green
*Update* button for the changes to take effect.

|image7|

Users
^^^^^

The Users tab lets you see the name for all users signed up, the number
of projects they've created, and the last time they logged onto Anaconda
Enterprise Notebooks.

|image8|

Security Log
^^^^^^^^^^^^

List of all errors that could affect security. Click the eye icon to
view the full detail for each log item. Click the Actor to navigate to
the user's profile page.

|image9|

|image10|

Data Centers
^^^^^^^^^^^^

View the current Datacenter information or add a new Data Center by
clicking the *Add Datacenter* button.

|image11|

You'll see the following form after you select *Add Datacenter*.

|image12|

Enter the Name, select Subdomain Routing or Https, enter the base domain
name, a summary description of the server, and then select the provider.
When you are finished hit the *Submit* button to add the new Data
Center.

Task Queue
^^^^^^^^^^

See the list of workers in the task queue and whether the task is high,
default or low priority. Also view the list of current queues sorted by
default or high priority. Click the priority level (default or high) to
view all the tasks in the queue.

|image13|

License
^^^^^^^

You'll find information on your Anaconda Enterprise Notebooks license in
the License tab of the Admin Settings. This includes the name of the
product, vendor, name, type, end date and when the license was issued.

Clicking on the *renew your license* button will open up a new tab with
the Anaconda Enterprise Notebooks site where you can easily renew your
license.

When you have a new license file, you can use the *Upload New License*
dialog box to add the file to your Anaconda Enterprise Notebooks
installation. Click the *Choose File* button, select the new license
file and click *Open*. You will be returned to the Admin Settings page
and will need to click the *Update* button for the new license to be
applied.

|image14|

Providers
~~~~~~~~~

Enterprise Resources
^^^^^^^^^^^^^^^^^^^^

View, add or remove local or cloud services, designate public or not to
control exactly who has access to this compute node.

|image15|

You can remove a Resource by clicking the red *remove* button. If you
click on the name of the resource, you'll proceed to the following
screen where you'll be able to find out more information about the
Resource and edit it.

|image16|

If you click on the green *Add Resource* button on either of these
screens, you'll be taken to a form where you can enter the information
to add another Resource to Anaconda Enterprise Notebooks.

|image17|

Top Utility Navigation Menu
~~~~~~~~~~~~~~~~~~~~~~~~~~~

Admin
^^^^^

The home page.

Users
^^^^^

List of users who are currently logged onto the system. Clicking on a
username navigates to its profiles screen. The profile displays a
summary of the projects created by that user and the list of projects
the user is currently contributing to.

|image18|

Profile (your username)
^^^^^^^^^^^^^^^^^^^^^^^

Shows information about your user account. It is the same view that
regular users have.

|image19|

New Project
^^^^^^^^^^^

Create a new project, give it a name and add a summary description.
Change the privacy to allow anyone to see to project or give access to
collaborators only.

|image20|

User Settings
^^^^^^^^^^^^^

Change your account settings: Public profile, email, password. This page
also shows a security log and the applications registered to use the
Anaconda Enterprise Notebooks API.

|image21|

Command-line Tools
------------------

Anaconda Enterprise Notebooks includes a set of command line utilities
that can be used to perform various administrative tasks. It is highly
recommended that these utility files are only owned by the Anaconda
Enterprise notebooks user and can only be executed by the Anaconda
Enterprise notebooks user.

List the WE Admin utilities:

::

    ls -al /opt/wakari/wakari-server/bin/wk-*

Execute these commands to set the owner and the file permissions:

::

    chown wakari:wakari /opt/wakari/wakari-server/bin/wk-*
    chmod 700 /opt/wakari/wakari-server/bin/wk-*

.. _`adding-administrative-users`:

Adding Administrative Users
~~~~~~~~~~~~~~~~~~~~~~~~~~~

The Administrative UI is only accessible by a user with special
privileges.

Some users can be designated as *superusers* or as *staff*, giving them
greater administrative privileges over the system. This can be done from
the command line on the Anaconda Enterprise Notebooks Server node using
the ``wk-server-admin superuser`` or ``wk-server-admin staff`` commands.

For example, to give the "wakari" user administrative privileges run the
following command:

::

    wk-server-admin superuser --add wakari

Deleting Users and Projects
~~~~~~~~~~~~~~~~~~~~~~~~~~~

The command ``wk-server-admin`` in Anaconda Enterprise can also be used
to remove users or projects from the data base:

For example, to remove a user whose username is "wakari" run the
following command:

::

    wk-server-admin remove-user wakari

The remove a project called "project1" created by the user "wakari"
execute the following code:

::

    wk-server-admin remove-project wakari project

For more information about each command use ``-h`` after it. The
following code will print additional information about the commands
presented above.

::

    wk-server-admin remove-user -h
    we-server-admin remove-project -h

Anaconda Environments
~~~~~~~~~~~~~~~~~~~~~

Each project has an associated conda environment containing the packages
needed for that project. When a project is first started, Anaconda
Enterprise Notebooks clones a default environment into the project
directory, with the name 'default'.

The default environment is the Anaconda root environment
(``/opt/wakari/anaconda``). To configure a customized default
environment, use conda to create an environment in
``/opt/wakari/anaconda/envs/default``:

::

    /opt/wakari/anaconda/bin/conda create -p /opt/wakari/anaconda/envs/default <packages>

You can then use
``conda install -p /opt/wakari/anaconda/envs/default <packages>`` and
``conda remove -p /opt/wakari/anaconda/envs/default <packages>``.


.. toctree::
    :maxdepth: 1

    configuration-files
    shutdown
    backup
    troubleshooting


.. toctree::
   :hidden:

   compute-nodes


.. |image0| image:: img/aen-admin-admin_image1.png
.. |image1| image:: img/aen-admin-admin_dailyreport.png
.. |image2| image:: img/aen-admin-admin_passreset.png
.. |image3| image:: img/aen-admin-admin_notification.png
.. |image4| image:: img/aen-admin-admin_except1.png
.. |image5| image:: img/aen-admin-admin_except2.png
.. |image6| image:: img/aen-admin-admin_general.png
.. |image7| image:: img/aen-admin-admin_accounts.png
.. |image8| image:: img/aen-admin-admin_users.png
.. |image9| image:: img/aen-admin-admin_securitylog1.png
.. |image10| image:: img/aen-admin-admin_securitylog2.png
.. |image11| image:: img/aen-admin-admin_datacenter1.png
.. |image12| image:: img/aen-admin-admin_datacenter2.png
.. |image13| image:: img/aen-admin-admin_taskqueue.png
.. |image14| image:: img/aen-admin-admin_license.png
.. |image15| image:: img/aen-admin-admin_enterpriseresources.png
.. |image16| image:: img/aen-admin-admin_er_editresource.png
.. |image17| image:: img/aen-admin-admin_er_addresource.png
.. |image18| image:: img/aen-admin-users_users.png
.. |image19| image:: img/aen-admin-users_profile.png
.. |image20| image:: img/aen-admin-users_newproject.png
.. |image21| image:: img/aen-admin-users_settings.png
