neuland-ingolstadt / neuland.app

A free & open source, web-based replacement for the official app of the Technische Hochschule Ingolstadt built with React and Next.js.
https://neuland.app
GNU Affero General Public License v3.0
36 stars 33 forks source link

Add a CI job for automatic deployments when pushing to develop and master #226

Closed M4GNV5 closed 2 weeks ago

M4GNV5 commented 1 year ago

Currently after pushing to the corresponding branches we have to manually log into the server and deploy the changes by running docer-compose up. Since only @alexhorn and me have access to the server other contributors cannot have their changes deployed.

We could set up a CI pipeline which automatically runs docker-compose up -d --build on our server after a push to develop and master. From my experience, the best way is to generate a ssh key for github and limit the commands that can be executed using this ssh key using the command=... option in the authorized_keys file.

shei99 commented 1 year ago

A different solution to this would be to:

Additionally, all the docker-compose files should be versioned in a separate repository.