Skip to content

Commit

Permalink
Nest the UI directory into a ctl subdir (#970)
Browse files Browse the repository at this point in the history
* Nest the UI directory into a `ctl` subdir

* move all of the client files into the ctl subdir

* update path references

* update the github workflow checks

* update the CHANGELOG
  • Loading branch information
ThomasLaPiana authored Aug 12, 2022
1 parent 6e7c80b commit 0f9c906
Show file tree
Hide file tree
Showing 218 changed files with 12 additions and 11 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/frontend_pr_checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
node-version: [16.x]
defaults:
run:
working-directory: clients/admin-ui
working-directory: clients/ctl/admin-ui
steps:
- name: Checkout
uses: actions/checkout@v2
Expand Down Expand Up @@ -55,13 +55,13 @@ jobs:

- name: Install dependencies
run: |
cd clients/admin-ui
cd clients/ctl/admin-ui
npm install
- name: Cypress run
uses: cypress-io/github-action@v4
with:
working-directory: clients/admin-ui
working-directory: clients/ctl/admin-ui
install: false
start: npm run cy:start
wait-on: "http://localhost:3000"
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/publish_package.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,12 @@ jobs:

- name: Install node modules
run: |
cd clients/admin-ui
cd clients/ctl/admin-ui
npm install
- name: Build and export frontend files
run: |
cd clients/admin-ui
cd clients/ctl/admin-ui
npm run prod-export
- name: Install Twine and wheel
Expand Down
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@ The types of changes are:
### Changed

* Upgraded base Docker version to Python 3.9 and updated all other references from 3.8 -> 3.9 [#974](https://github.com/ethyca/fides/pull/974)
* Moved the `admin-ui` code down one level into a `ctl` subdir [#970](https://github.com/ethyca/fides/pull/970)

## [1.8.1](https://github.com/ethyca/fides/compare/1.8.0...1.8.1) - 2022-08-08

Expand Down
6 changes: 3 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,10 @@ RUN pip install -U pip
####################
FROM node:16 as frontend

WORKDIR /fides/clients/admin-ui
WORKDIR /fides/clients/ctl/admin-ui

# install node modules
COPY clients/admin-ui/ .
COPY clients/ctl/admin-ui/ .
RUN npm install

# Build the frontend static files
Expand Down Expand Up @@ -112,7 +112,7 @@ RUN pip install --no-deps -e ".[all,mssql]"
FROM builder as prod

# Copy frontend build over in order to be available in wheel package
COPY --from=frontend /fides/clients/admin-ui/out/ /fides/src/fidesctl/ui-build/static/admin/
COPY --from=frontend /fides/clients/ctl/admin-ui/out/ /fides/src/fidesctl/ui-build/static/admin/

# Install without a symlink
RUN python setup.py bdist_wheel
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
"analyze:server": "cross-env BUNDLE_ANALYZE=server next build",
"analyze:browser": "cross-env BUNDLE_ANALYZE=browser next build",
"export": "next build && next export",
"copy-export": "mkdir -p ../../src/fidesctl/ui-build/static/admin/ && rsync -a --delete out/ ../../src/fidesctl/ui-build/static/admin/",
"copy-export": "mkdir -p ../../../src/fidesctl/ui-build/static/admin/ && rsync -a --delete out/ ../../../src/fidesctl/ui-build/static/admin/",
"prod-export": "npm run export && npm run copy-export",
"cy:open": "cypress open",
"cy:run": "cypress run",
Expand Down
File renamed without changes.
File renamed without changes
File renamed without changes
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -18,10 +18,10 @@ These files can by regenerated by running:
npm run openapi:generate
```

**The fidesctl server must be running on `localhost:8080`**. This will read the schema hosted at http://localhost:8080/docs and generate all TS files under `clients/admin-ui/src/types/api/`.
**The fidesctl server must be running on `localhost:8080`**. This will read the schema hosted at http://localhost:8080/docs and generate all TS files under `clients/ctl/admin-ui/src/types/api/`.


## Resources

- [FastAPI Client Generation](https://fastapi.tiangolo.com/advanced/generate-clients/?h=typescript#install-openapi-typescript-codegen)
- [OpenAPI Typescript Codegen](https://github.com/ferdikoomen/openapi-typescript-codegen)
- [OpenAPI Typescript Codegen](https://github.com/ferdikoomen/openapi-typescript-codegen)
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 0f9c906

Please sign in to comment.