Skip to content

Commit

Permalink
Collapse step 2 and 3
Browse files Browse the repository at this point in the history
  • Loading branch information
simonepelosi committed Jun 17, 2024
1 parent 05269b1 commit d8430d3
Showing 1 changed file with 12 additions and 13 deletions.
25 changes: 12 additions & 13 deletions how-to/manage-users.rst
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,9 @@ Manage users and teams in development environments
Create new users
----------------

Local
~~~~~

In environments that use the test OpenID provider, such as the development
appserver started via ``make run``, you can create a new account using the
``utilities/make-lp-user`` script and log into that account at
Expand All @@ -12,15 +15,16 @@ appserver started via ``make run``, you can create a new account using the
For example, to add user ``test-user``, navigate to your local Launchpad repo
and run: ``utilities/make-lp-user test-user``.

Staging/Qastaging
~~~~~~~~~~~~~~~~~

Some development environments, such as those deployed using the :doc:`Mojo
spec <../explanation/charms>`, use production Single Sign-On for
authentication. In these environments, you should not use
``utilities/make-lp-user``; instead, log into
``https://{qastaging,staging}.launchpad.net/`` via SSO as you would on
production to create your user.



Add user to a team
------------------

Expand All @@ -29,23 +33,18 @@ following handler ``~test-user`` and we want to add it to a team. In this
example let's consider that we want to add it to the Launchpad Admins team,
so ``~admins``.

We can use the ``utilities/anoint-team-member`` script within the Launchpad repo
to add a user to a team.
We can use the ``utilities/anoint-team-member`` script within the Launchpad
repo for this purpose.

For staging and qastaging we should:

1. Log into ``launchpad-bastion-ps5`` using
the ``stg-launchpad`` user.

2. Source ``. .mojorc.{qastaging,staging}`` the correct
environment.

3. Ssh into the scripts unit ``juju ssh launchpad-scripts/leader``.

.. note::
Alternatively, we can merge step 2,3 running this command:
``in-model qastaging juju ssh launchpad-scripts/leader``
2. SSH into the ``launchpad-scripts`` juju unit, by running
``in-model qastaging juju ssh launchpad-scripts/leader``.

4. Then we can run:
3. Add the user to the team by running:

.. code::
Expand Down

0 comments on commit d8430d3

Please sign in to comment.