A simpler alternative to Nextcloud and ownCloud, built with TypeScript and Deno using Fresh. 🦕 🍋 https://bewcloud.com/
Find a file
Bruno Bernardino 2e995cc9f7
Some checks failed
Build Docker Image / build-and-push (push) Has been cancelled
Deploy / deploy (push) Has been cancelled
Run Tests / test (push) Has been cancelled
Update Deno
2025-02-02 07:30:45 +00:00
.do Update Deno to 2.1 LTS! 2024-11-30 08:13:22 +00:00
.github add arm64 build to workflows 2024-12-08 08:58:13 +00:00
.vscode Make it public! 2024-03-16 08:40:24 +00:00
components Implement bulk delete in files 2024-09-02 16:09:30 +01:00
crons Finally fix the deletion of old articles and add funding manifest URL 2024-10-16 15:10:03 +01:00
db-migrations Simplify migration SQL. 2024-11-21 14:03:08 +00:00
islands Add Photos UI 2024-04-27 08:12:44 +01:00
lib Add example .env var, fix linting 2025-01-11 07:14:02 +00:00
routes Minor UX and code improvements 2024-12-06 06:08:15 +00:00
static Update Deno to 2.1 LTS! 2024-11-30 08:13:22 +00:00
.dvmrc Update Deno 2025-02-02 07:30:45 +00:00
.env.sample Add example .env var, fix linting 2025-01-11 07:14:02 +00:00
.gitignore Files CRUD. 2024-04-03 14:02:04 +01:00
deno.json Update Deno to 2.1 LTS! 2024-11-30 08:13:22 +00:00
dev.ts Make it public! 2024-03-16 08:40:24 +00:00
docker-compose.dev.yml Build + offer docker image and docker-compose.yml file for easier self-hosting 2024-04-09 13:22:05 +01:00
docker-compose.yml Update Deno to 2.1 LTS! 2024-11-30 08:13:22 +00:00
Dockerfile Update Deno 2025-02-02 07:30:45 +00:00
fresh.config.ts Make it public! 2024-03-16 08:40:24 +00:00
fresh.gen.ts Implement bulk delete in files 2024-09-02 16:09:30 +01:00
LICENSE Make it public! 2024-03-16 08:40:24 +00:00
main.ts Make it public! 2024-03-16 08:40:24 +00:00
main_test.ts Implement bulk delete in files 2024-09-02 16:09:30 +01:00
Makefile Make it public! 2024-03-16 08:40:24 +00:00
migrate-db.ts Fail with exit code if migration fails 2024-11-21 14:16:55 +00:00
README.md Add proper locking/unlocking to WebDAV. 2024-05-05 08:09:34 +01:00
render.yaml Update Deno, update Render deploy file 2024-12-26 11:54:42 +00:00
tailwind.config.ts Make it public! 2024-03-16 08:40:24 +00:00

bewCloud

This is the bewCloud app built using Fresh and deployed using docker compose.

If you're looking for the desktop sync app, it's at bewcloud-desktop.

If you're looking for the mobile app, it's at bewcloud-mobile.

Self-host it!

Deploy to DigitalOcean

Deploy to Render

Or on your own machine:

Download/copy docker-compose.yml and .env.sample as .env.

$ docker compose up # makes the app available at http://localhost:8000
$ docker compose run website bash -c "cd /app && make migrate-db" # initializes/updates the database (only needs to be executed the first time and on any updates)

Alternatively, check the Development section below.

Important

Even with signups disabled (CONFIG_ALLOW_SIGNUPS="false"), the first signup will work and become an admin.

Development

Requirements

  • Don't forget to set up your .env file based on .env.sample.
  • This was tested with Deno's version stated in the .dvmrc file, though other versions may work.
  • For the postgres dependency (used when running locally or in CI), you should have Docker and docker compose installed.

Commands

$ docker compose -f docker-compose.dev.yml up # (optional) runs docker with postgres, locally
$ make migrate-db # runs any missing database migrations
$ make start # runs the app
$ make format # formats the code
$ make test # runs tests

Other less-used commands

$ make exec-db # runs psql inside the postgres container, useful for running direct development queries like `DROP DATABASE "bewcloud"; CREATE DATABASE "bewcloud";`
$ make build # generates all static files for production deploy

Structure

  • Routes defined at routes/.
  • Static files are defined at static/.
  • Frontend-only components are defined at components/.
  • Isomorphic components are defined at islands/.
  • Cron jobs are defined at crons/.
  • Reusable bits of code are defined at lib/.
  • Database migrations are defined at db-migrations/.

Deployment

Just push to the main branch.

Where's Contacts/Calendar (CardDav/CalDav)?! Wasn't this supposed to be a core Nextcloud replacement?

Check this tag/release for more info and the code where/when that was being done. Contacts/CardDav worked and Calendar/CalDav mostly worked as well at that point.

My focus was to get me to replace Nextcloud for me and my family ASAP, and it turns out it's not easy to do it all in a single, installable thing, so I focused on the Files UI, sync, and sharing, since Radicale solved my other issues better than my own solution (and it's already very efficient).

How does file sharing work?

Check this PR for advanced sharing with internal and external users, with read and write access that was being done and almost working. I ditched all that complexity for simply using symlinks, as it served my use case (I have multiple data backups and trust the people I provide accounts to, with the symlinks).

You can simply ln -s /<absolute-path-to-data-files>/<owner-user-id>/<directory-to-share> /<absolute-path-to-data-files>/<user-id-to-share-with>/ to create a shared directory between two users, and the same directory can have different names, now.

Note

If you're running the app with docker, the symlink needs to point to the container's directory, usually starting with /app if you didn't change the Dockerfile, otherwise the container will fail to load the linked directory.

How does it look?

Check the website for screenshots or the YouTube channel for 1-minute demos.