Skip to content

Simple page to show free rooms from your Google Apps account

License

Notifications You must be signed in to change notification settings

dpca/whats-free

Repository files navigation

Build Status Code Climate Coverage Status


whats-free

Simple page to show free rooms from your Google Apps account

Development

yarn start

Google API configuration

Go to console.developers.google.com, create a project, and enable the Google Calendar API. Create OAuth 2.0 credentials for both a Web application and API key. Create a .env file with REACT_APP_GOOGLE_CLIENT_ID with the Client ID from the Web application credentials and REACT_APP_GOOGLE_API_KEY with the API key from the API key credentials. Authorize javascript origins for whatever domain/IP you want to run on in the Web application section.

Calendar configuration

Create a src/calendar.json file with information about the calendars you wish to watch. It should contain a list of calendar objects having id, name, and group fields:

[
  {
    "id": "XXXXXXXXXX@resource.calendar.google.com",
    "name": "Example room 1",
    "group": "8th floor"
  },
  ...
]

Deploy

yarn build
scp build/* SERVER

Server configuration

Install nginx and set it up to serve the static files in the build/ directory (edit the /etc/nginx/sites-available/default file to point root to the location of the build folder)

Or, use a Dockerfile like the following:

FROM nginx
COPY build/ /usr/share/nginx/html
CMD ["nginx", "-g", "daemon off;"]

About

Simple page to show free rooms from your Google Apps account

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published