Skip to content

Commit

Permalink
refactor(admin): remove admin application (#1792)
Browse files Browse the repository at this point in the history
Motivation
----------
If we implement role-based authorization, we will enforce it in the
backend and we will teach the frontend how to show a separate interface
to users with a role `admin`.

This PR will improve the following:

* Less dependencies + dependabot PRs
* Less workflows to run
* Less code duplication
* Less memory consumption in our kubernetes cluster
* Less domains to generate certificates for
* Less potential for CORS issues
* Less containers running in `docker-compose`
* Less disk usage on our laptops

How to test
-----------
1. After this gets merged, we should test our vServer deployment

close #1785
  • Loading branch information
roschaefer authored Aug 19, 2024
1 parent 4642bd4 commit 1ced64d
Show file tree
Hide file tree
Showing 125 changed files with 4 additions and 27,978 deletions.
2 changes: 0 additions & 2 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@ updates:
open-pull-requests-limit: 99
directories:
- "/"
- "/admin"
- "/backend"
- "/frontend"
- "/presenter"
Expand Down Expand Up @@ -105,7 +104,6 @@ updates:
directories:
- "/"
- "/authentik"
- "/admin"
- "/backend"
- "/frontend"
- "/presenter"
Expand Down
21 changes: 0 additions & 21 deletions .github/workflows/admin.deploy.chromatic.yml

This file was deleted.

75 changes: 0 additions & 75 deletions .github/workflows/admin.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .github/workflows/deployment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
build-and-push-images:
strategy:
matrix:
folder: [authentik, admin, backend, frontend, presenter]
folder: [authentik, backend, frontend, presenter]
runs-on: ubuntu-latest
env:
REGISTRY: ghcr.io
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/pr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ jobs:
# Configure which scopes are allowed (newline delimited).
# Append a scope for each service here
scopes: |
admin
authentik
backend
deps
Expand Down
19 changes: 1 addition & 18 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ Dreammall.earth websites & services

## Modules

- [Admin](admin/README.md)
- [Authentik](authentik/README.md)
- [Backend](backend/README.md)
- [Deployment](deployment/README.md)
Expand Down Expand Up @@ -50,7 +49,7 @@ docker compose run --rm backend npm run db:reset

Start your desired applications:
```bash
docker compose up admin backend frontend presenter
docker compose up backend frontend presenter
```

## B) Run applications locally
Expand All @@ -63,13 +62,6 @@ Set a temporary variable for the upcoming steps:
export rootFolder=$(pwd)
```

Setup admin:
```bash
cd $rootFolder/admin
cp .env.dist .env
npm install
```

Setup backend:
```bash
cd $rootFolder/backend
Expand All @@ -94,13 +86,6 @@ npm install

### Start Services

Now start all of these in separate terminals:
```bash
cd admin
export PORT=3002
npm run dev
```

```bash
cd backend
npm run dev
Expand Down Expand Up @@ -128,8 +113,6 @@ The following endpoints are provided for `docker compose up`:
| [http://localhost:6006](http://localhost:6006) | Presenter Storybook |
| [http://localhost:3001](http://localhost:3000) | Frontend |
| [http://localhost:6007](http://localhost:6007) | Frontend Storybook |
| [http://localhost:3002](http://localhost:3002) | Admin |
| [http://localhost:6008](http://localhost:6008) | Admin Storybook |
| [http://localhost:4000](http://localhost:4000) | Backend GraphQL Playground |
| [http://localhost:8080](http://localhost:8080) | Documentation |
| [http://localhost:8080](http://localhost:8025) | Mailpit |
Expand Down
3 changes: 0 additions & 3 deletions admin/.dockerignore

This file was deleted.

5 changes: 0 additions & 5 deletions admin/.env.dist

This file was deleted.

5 changes: 0 additions & 5 deletions admin/.env.production

This file was deleted.

4 changes: 0 additions & 4 deletions admin/.eslintignore

This file was deleted.

Loading

0 comments on commit 1ced64d

Please sign in to comment.