-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
base: next
Are you sure you want to change the base?
Conversation
retries: 3 | ||
start_period: 10s | ||
|
||
caddy: |
There was a problem hiding this comment.
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
There was a problem hiding this comment.
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
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}
}
}
}
There was a problem hiding this comment.
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.
There was a problem hiding this comment.
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:
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.
Changes
Github:
Main site: