ucsb-cs156-s23 / team02-s23-7pm-3

https://ucsb-cs156-s23.github.io/team02-s23-7pm-3/
0 stars 0 forks source link

STARTER-team02

Configuring GitHub Pages for the documentation

This repo contains Github Actions scripts that automatically create and publish documentation for the code:

To set this up, follow the instructions here: docs/github-pages.md

Getting Started on localhost

Before running the application for the first time on localhost, you must:

Otherwise, when you try to login for the first time, you will likely see an error such as:

Authorization Error; Error 401: invalid_client; The OAuth client was not found.

Then:

The app should be available on http://localhost:8080

Note: http://localhost:8080 not http://localhost:3000

The npm start command may open up a web browser with the app running on port http://localhost:3000.

What if it doesn't work?

If it doesn't work at first, e.g. you have a blank page on http://localhost:8080, give it a minute and a few page refreshes. Sometimes it takes a moment for everything to settle in.

If you see the following on localhost, make sure that you also have the frontend code running in a separate window.

Failed to connect to the frontend server... 

On Dokku, be sure that PRODUCTION is defined. 

On localhost, open a second terminal window, 
cd into frontend and type: npm install; npm start";

Getting Started on Dokku

Accessing swagger

Swagger is a tool that allows you to work directly with the RESTful API endpoints of the backend. It is similar to the tool Postman, but more convenient because it is built directly into the application.

To access the Swagger API endpoints, use:

You can also append /swagger-ui/index.html to the URL manually when running on Dokku.

To run React Storybook locally (for development)

You can also see the storybook for the main branch and all open pull requests on the github pages site associated with the repo; see /docs/github-pages.md for more info.

To generate javadoc (locally, for development)

You can also see the javadoc for the main branch and all open pull requests on the github pages site associated with the repo; see /docs/github-pages.md for more info.

SQL Database access

On localhost:

On Dokku: