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: ensure data_volume isn't surrounded by quotes #21473

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Aletor93
Copy link

Comprehensive Summary of your change

I'm generating harbor.yaml file with erb function to_yaml, where strings containing / are quoted. It can't be configured.

When I run ./install.sh script, it fails on docker volume command due to quotes which aren't removed:

prepare base dir is set to /srv/harbor/install
docker: Error response from daemon: create "/srv/harbor/data": "\"/srv/harbor/data\"" includes invalid characters for a local volume name, only "[a-zA-Z0-9][a-zA-Z0-9_.-]" are allowed. If you intended to pass a host directory, use absolute path.
See 'docker run --help'.

After editing the prepare script to remove quotes on data_volume if present, it works like a charm. The sed is already used in other scripts, it shouldn't be a problem to use it.

Issue being fixed

n/a (no issue opened)

Please indicate you've done the following:

  • Well Written Title and Summary of the PR
  • Label the PR as needed. "release-note/ignore-for-release, release-note/new-feature, release-note/update, release-note/enhancement, release-note/community, release-note/breaking-change, release-note/docs, release-note/infra, release-note/deprecation"
  • Accepted the DCO. Commits without the DCO will delay acceptance.
  • Made sure tests are passing and test coverage is added if needed.
  • Considered the docs impact and opened a new docs issue or PR with docs changes if needed in website repository.

@Aletor93 Aletor93 force-pushed the aletor93/fix-data-volume-path-remove-quotes branch from 9e75874 to 22bb9a5 Compare January 31, 2025 09:17
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.

4 participants