Simple page to show free rooms from your Google Apps account
yarn start
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.
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"
},
...
]
yarn build
scp build/* SERVER
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;"]