Skip to content

feat: added chibisafe template #5808

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 5 commits into
base: next
Choose a base branch
from
Open

Conversation

nktnet1
Copy link
Contributor

@nktnet1 nktnet1 commented May 12, 2025

Changes

  • added template for chibisafe

Github:

Main site:


chibisafe is a beautiful and performant vault to save all your files in the cloud.

A modern and self-hosted take on file uploading services that can handle anything you throw at it thanks to it's robust and fast API, chunked uploads support and more.

@nktnet1 nktnet1 changed the title Chibisafe feat: added chibisafe template May 12, 2025
@nktnet1 nktnet1 changed the base branch from v4.x to next May 12, 2025 14:03
retries: 3
start_period: 10s

caddy:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A full proxy is not needed as Coolify does the domain part so this should be removed. And let Coolify handle domains for the service via the magic ENVs

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I thought the same, but then I saw this in the docs: https://chibisafe.moe/guides/running-with-docker

image

text version

Even if you use NGINX Proxy Manager, or Caddy in your host system, it is still necessary to have Caddy inside the docker compose file. Do not change these options unless you know what you are doing, otherwise you'll break the routing.

I think it's still possible to do it, although there'll need to be a way to configure traefik/caddy the same way as their given Caddyfile

# chibisafe/Caddyfile
{$BASE_URL} {
	route {
		file_server * {
				root /app/uploads
				pass_thru
		}

		@api path /api/*
		reverse_proxy @api http://chibisafe_server:8000 {
				header_up Host {http.reverse_proxy.upstream.hostport}
				header_up X-Real-IP {http.request.header.X-Real-IP}
		}

		@docs path /docs*
		reverse_proxy @docs http://chibisafe_server:8000 {
				header_up Host {http.reverse_proxy.upstream.hostport}
				header_up X-Real-IP {http.request.header.X-Real-IP}
		}

		reverse_proxy http://chibisafe:8001 {
				header_up Host {http.reverse_proxy.upstream.hostport}
				header_up X-Real-IP {http.request.header.X-Real-IP}
		}
	}
}

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes it should be possible just add 3 domains 1 api, 1 docs and 1 for 8001 and then it should work with the magic.

Copy link
Contributor Author

@nktnet1 nktnet1 May 16, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, are you able to provide suggestions using the code snippets for how this can be done?

I've tried a couple things, including

# documentation: https://chibisafe.moe/guides
# slogan: A beautiful and performant vault to save all your files in the cloud.
# tags: storage,file-sharing,upload,sharing
# logo: svgs/chibisafe.svg
# port: 8001

services:
  chibisafe:
    image: chibisafe/chibisafe:latest
    environment:
      - SERVICE_FQDN_CHIBISAFE_8001
      - SERVICE_FQDN_API_8000=/api
      - SERVICE_FQDN_DOCS_8000=/docs
    healthcheck:
      test: ["CMD", "wget", "--spider", "--quiet", "http://127.0.0.1:8001"]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 10s

  chibisafe_server:
    image: chibisafe/chibisafe-server:latest
    volumes:
      - database:/app/database:rw
      - uploads:/app/uploads:rw
      - logs:/app/logs:rw
    healthcheck:
      test:
        [
          "CMD",
          "wget",
          "--spider",
          "--quiet",
          "http://127.0.0.1:8000/api/health",
        ]
      interval: 30s
      timeout: 10s
      retries: 3
      start_period: 10s

But it always result in a 404.

Also, when using something like the following from the docs:
image

Will it retain the base path (/api) when proxying to the new port?
Or is it something like http://frontend:8001/api/example/path -> http://backend:8000/example/path, which starts from root.

@peaklabs-dev peaklabs-dev added the 💤 Waiting for changes PRs awaiting changes from the author. label May 14, 2025
@nktnet1 nktnet1 marked this pull request as draft May 14, 2025 22:43
@nktnet1 nktnet1 marked this pull request as ready for review May 14, 2025 23:03
@peaklabs-dev peaklabs-dev added ⚙️ Service Issues requesting or PRs adding/fixing service templates. and removed 💤 Waiting for changes PRs awaiting changes from the author. labels May 23, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
⚙️ Service Issues requesting or PRs adding/fixing service templates.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants