Skip to content
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

fix(filebrowser): support custom base_url in case of custom db path #320

Merged
merged 6 commits into from
Oct 18, 2024

Conversation

yandolfat
Copy link
Contributor

Proposal to fix #309.

@matifali
Copy link
Member

Hi @yandolfat, do you plan to come back to this PR? I would be happy to complete this if you are not available. Thanks for the PR.

@yandolfat
Copy link
Contributor Author

Hi @yandolfat, do you plan to come back to this PR? I would be happy to complete this if you are not available. Thanks for the PR.

Hi, if there is nothing to add, you can complete it, thanks :)

@matifali
Copy link
Member

@yandolfat Could you test the updated functionality by setting the source as

module "filebrowser" {
  source     = "git::https://github.com/yandolfat/modules.git//filebrowser?ref=patches/filebrowser"
  agent_id   = coder_agent.example.id
  agent_name = "main"
  subdomain  = false
}

@yandolfat
Copy link
Contributor Author

"git::https://github.com/yandolfat/modules.git//filebrowser?ref=patches/filebrowser"

Seems to work :)

https://imgur.com/a/YTpEWY5

@@ -18,7 +18,7 @@ if [ "${DB_PATH}" != "filebrowser.db" ]; then
fi

# set baseurl to be able to run if sudomain=false; if subdomain=true the SERVER_BASE_PATH value will be ""
filebrowser config set --baseurl "${SERVER_BASE_PATH}" > ${LOG_PATH} 2>&1
filebrowser config set --baseurl "${SERVER_BASE_PATH}"$${DB_FLAG} > ${LOG_PATH} 2>&1
Copy link
Member

Choose a reason for hiding this comment

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

@yandolfat Why is this required here if we specify DB_FLAG while running filebrowser in line 27.?

I think we would need it only once either in config or while running.

@matifali matifali merged commit 20d97a2 into coder:main Oct 18, 2024
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

bug(filebrowser): Base URL Configuration Issue in FileBrowser Module
2 participants