Skip to content

Embed a highly customizable web calendar into your website using ICal source links

License

Notifications You must be signed in to change notification settings

corybrewis/open-web-calendar

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Open Web Calendar

GitHub Workflow Status Support on Open Collective build and publish the Docker image

You might want to:

Python: 3.7, 3.8, 3.9, 3.10

There are several commercial solutions which allow embedding of calendars into my website. I only have a link to an ICS file and want to show a nice-looking calendar on my site. Browser-only calendars usually have the problem that many ICS files can not be accessed (such as ownCloud/nextCloud in my case). I also want to be in control over who knows the people who visit the site and not pass everything to Google. This is a solution in my case which I share with the world. You are free to use it or deploy your own, modify or share it. It works offline and in company networks, too.

Features

  • Embedded calendar
  • Choice of time zone
  • ICS link, best multiple
  • month/week as a view
  • name, time of event, link?
  • showing the time span
  • styling of choice (icon, color, font, ...)

Contributing

There are several ways in which you can help this project:

Translation

You can help us by translating the project to your language. If your language is not listed, please request to add it!

Here, you can see the current translation status:

Translation status

Deployment

There are several ways to deploy the open-web-calendar.

Environment Variables - Configuration

These environment variables can be used to configure the service:

  • APP_DEBUG default true, values true or false, always false in the Docker container Set the debug flag for the app.
  • PORT default 5000, default 80 in the Docker container
    The port that the service is running on.
  • WORKERS default 4 only for the Docker container
    The number of parallel workers to handle requests.
  • CACHE_REQUESTED_URLS_FOR_SECONDS default 600
    Seconds to cache the calendar files that get downloaded to reduce bandwidth and delay.

Docker

To build the container yourself type the command

docker build --tag niccokunzmann/open-web-calendar .

You can also use the existing image: niccokunzmann/open-web-calendar.

docker run -d --rm -p 5000:80 niccokunzmann/open-web-calendar

Then, you should see your service running at http://localhost:5000.

Container Tags

The container niccokunzmann/open-web-calendar:latest contains the latest release. Containers are also tagged with the version from the changelog, e.g. niccokunzmann/open-web-calendar:v1.10. If you wish to run the latest development version, use niccokunzmann/open-web-calendar:master.

Docker Compose

Using pre build dockerhub image with docker-compose

version: '3'
services:
  open-web-calendar:
    image: niccokunzmann/open-web-calendar
    ports:
      - '80:80'
    environment:
      - WORKERS=4
    restart: unless-stopped

To deploy the open-web-calendar with docker-compose, do the following steps:

  1. Copy the docker-compose.yml file to the directory from where you want to run the container.
  2. If needed change port mapping and environment variables.
  3. Type docker-compose up -d to start the container.
  4. The container will be pulled automatically from dockerhub and then starts.

Important Note: If you use this service, consider setting up log rotation as it is very talkative.

Update prebuild image with Docker Compose

If you want to update your image with the latest version from dockerhub type docker-compose pull

Note: You need to start the container after pulling again in order for the update to apply (docker-compose up -d)

Vercel

You can create a fork of this repository which automatically deploys to Vercel:

Deploy

Alternatively you can create a one off deploy by cloning this repository and running npx vercel at the root.

Heroku

You can deploy the app using Heroku.

Deploy

Heroku uses gunicorn to run the server, see the Procfile.

Research

Hosts

Sources/Libs

Search Terms

calendar ics service, ics calendar to html, open source calendar view ical, python Ical, calendar viewer website for ics, open source calendar website, embed calendar into website

Software Components

Development

  1. Optional: Install virtualenv and Python3 and create a virtual environment.
    virtualenv -p python3 ENV
    source ENV/bin/activate
    
  2. Install the packages.
    pip install -r requirements.txt
    
  3. Start the app.
    python3 app.py
    

For the configuration of the app through environment variables, see the app.json file.

Running Tests

To run the tests, we use tox. tox tests all different Python versions which we want to be compatible to.

pip install tox

Run all tests:

tox

Run a specific Python version:

tox -e py39

Updating Dependencies

We use pip-compile to guarantee a tested deployment by fixing all the dependencies to a specific version.

You can update the packages to the latest version:

rm requirements.txt test-requirements.txt
pip install --upgrade pip-tools -r requirements.in -r test-requirements.in
pip-compile -o requirements.txt requirements.in
pip-compile -o test-requirements.txt test-requirements.in

And run the tests:

tox

Changelog

  • v1.13
    • Improve French calendar
    • Update dependencies
  • v1.12
    • Add Croatian UI by Milo Ivir
  • v1.11
    • Add German UI
    • Improve calendar in Polish
    • Add Welsh calendar
  • v1.10
    • Add translations for nb_NO.
    • Translate the user interface.
    • Use weblate to translate files.
  • v1.9
  • v1.8
  • v1.7
  • v1.6
    • Add choice of Sunday or Monday for the start of the week Issue 39 - backed by donation!
  • v1.5
  • v1.4
    • add event categories when you click an event, see PR 159.
  • v1.3
    • update translation mistake
    • fix encoding problem for languages other than en/de
    • add ability to remove all controls
    • test with GitHub actions
    • test user interface
  • v1.2
  • v1.1
    • Add Coatian Language by Tomislav Gomerčić
  • v1.0

Release a new Version

To release a new version:

  1. Edit the README.md file in the Changelog Section and add the changes.
    git add README.md
    git commit -m"Modify changelog for release"
    git push
    
  2. Create a tag for the version.
    git tag v1.6
    git push origin v1.6
    
  3. Notify solved issues about the release.

Related Work

About

Embed a highly customizable web calendar into your website using ICal source links

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Python 46.8%
  • JavaScript 26.0%
  • HTML 18.1%
  • CSS 6.5%
  • Gherkin 1.8%
  • Shell 0.4%
  • Other 0.4%