From fd1ca851ed9ac83b83ceb20cc7fa34b65df05fa5 Mon Sep 17 00:00:00 2001 From: Alysia Broddrick Date: Mon, 8 May 2023 14:23:03 -0700 Subject: [PATCH 1/2] update with steps on accessing /admin --- docs/developer/README.md | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/docs/developer/README.md b/docs/developer/README.md index 91ac62b70..f55986ab5 100644 --- a/docs/developer/README.md +++ b/docs/developer/README.md @@ -34,6 +34,26 @@ DJANGO_SECRET_LOGIN_KEY="<...>" You'll need to create the `.env` file yourself. Get the secrets from Cloud.gov by running `cf env getgov-YOURSANDBOX`. More information is available in [rotate_application_secrets.md](../operations/runbooks/rotate_application_secrets.md). +## Adding user to /admin + +To be able to view and use /admin locally: + +1. Login via login.gov +2. Go to the home page and make sure you can see the part where you can submit an application +3. Go to /admin and it will tell you that UUID is not authorized, copy that UUID for use in 4 +4. in src/registrar/fixtures.py add to the ADMINS list in that file by adding your UUID as your username along with your first and last name. See below: + +``` + ADMINS = [ + { + "username": "", + "first_name": "", + "last_name": "", + }, + ... + ] +``` + ## Viewing Logs If you run via `docker-compose up`, you'll see the logs in your terminal. From 1ea3a743fd4b1de45b91cb5d1bc58d755b88a431 Mon Sep 17 00:00:00 2001 From: Alysia Broddrick Date: Mon, 8 May 2023 15:07:50 -0700 Subject: [PATCH 2/2] added information on what you should see after being granted /admins access --- docs/developer/README.md | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/docs/developer/README.md b/docs/developer/README.md index f55986ab5..404c18f23 100644 --- a/docs/developer/README.md +++ b/docs/developer/README.md @@ -36,7 +36,7 @@ You'll need to create the `.env` file yourself. Get the secrets from Cloud.gov b ## Adding user to /admin -To be able to view and use /admin locally: +The endpoint /admin can be used to view and manage site content, including but not limited to user information and the list of current applications in the database. To be able to view and use /admin locally: 1. Login via login.gov 2. Go to the home page and make sure you can see the part where you can submit an application @@ -54,6 +54,8 @@ To be able to view and use /admin locally: ] ``` +5. In the browser, navigate to /admins. To verify that all is working correctly, under "domain applications" you should see fake domains with various fake statuses. + ## Viewing Logs If you run via `docker-compose up`, you'll see the logs in your terminal.