Warning
This repository is archived and in a read-only state. You are welcome to download, clone, or fork this code, but please be aware that it is no longer actively maintained and may contain bugs or security vulnerabilities.
Interested in reviving this project? If you would like to restore development activities, please contact the team at help@finos.org.
This code builds the page hosted on https://calendar.finos.org , which is also embedded on https://www.finos.org/calendar , in order to provide a fully hosted solution that shows all events in the FINOS Community (Google) Calendar that can be correctly visualised also behind a corporate firewall.
A Github action runs periodically to fetch events using Google APIs (see src/googleapi2events.js) and renders out a JSON file in dist/events.json.
The calendar is visualized in HTML using React and FullCalendar.
- Node.js, npm and GPG(/GNUPG) installed on your machine.
- Clone the repository:
git clone https://github.com/finos/calendar.git
cd calendar- Download
calendar-service-account.jsoninto the project's root folder.
In order to use the Google Calendar API you will need to follow these 5 steps to generate the necessary credentials for a Service Account. Once you have the credentials store them in the root folder of the project in a file named calendar-service-account.json.
gpg --symmetric --cipher-algo AES256 calendar-service-account.json
:::note FINOS-Specific
Following this procedure creates the file calendar-service-account.json.gpg which can be safely committed to the repository. The decryption key for the checked-in version of this file can be found in the FINOS 1 Password folder.
:::
gpg --decrypt calendar-service-account.json.gpg > calendar-service-account.json
export GOOGLE_APPLICATION_CREDENTIALS=`cat calendar-service-account.json````
This will be used by Gatsby's endpoints for the Google Calendar API.
npm installCreate a new directory named dist in the root directory and run :
npm run get-eventsCopy events.json from dist to root directory.
npm startOpen browser to http://localhost:8000/.
https://calendar.finos.org is served by Github Pages and deployed by the build.yml Github Action.
Tests are implemented using testing-library/react and vitest.
npm run test