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

Fixed update_run.sh path and permission #84

Closed
wants to merge 2 commits into from

Conversation

mbreevoort
Copy link

@mbreevoort mbreevoort commented Nov 16, 2021

Wouldn't start on my Mac, probably needs the absolute path to the file

Description

Fixed path to update_run.sh (couldn't mount the relative path)
Permissions fix when run the script

Author Validation

After this fix docker-compose up starts correct.

Reviewer Tasks

Test if docker-compose up still starts

Wouldn't start on my Mac, probably needs the absolute path to the file
Copy link
Contributor

@ybyzek ybyzek left a comment

Choose a reason for hiding this comment

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

@mbreevoort thanks for the PR!

@@ -27,8 +27,8 @@ services:
KAFKA_CONTROLLER_LISTENER_NAMES: 'CONTROLLER'
KAFKA_LOG_DIRS: '/tmp/kraft-combined-logs'
volumes:
- ./update_run.sh:/tmp/update_run.sh
command: "bash -c 'if [ ! -f /tmp/update_run.sh ]; then echo \"ERROR: Did you forget the update_run.sh file that came with this docker-compose.yml file?\" && exit 1 ; else /tmp/update_run.sh && /etc/confluent/docker/run ; fi'"
- ${PWD}/update_run.sh:/tmp/update_run.sh
Copy link
Contributor

Choose a reason for hiding this comment

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

@mbreevoort good catch

- ./update_run.sh:/tmp/update_run.sh
command: "bash -c 'if [ ! -f /tmp/update_run.sh ]; then echo \"ERROR: Did you forget the update_run.sh file that came with this docker-compose.yml file?\" && exit 1 ; else /tmp/update_run.sh && /etc/confluent/docker/run ; fi'"
- ${PWD}/update_run.sh:/tmp/update_run.sh
command: "bash -c 'if [ ! -f /tmp/update_run.sh ]; then echo \"ERROR: Did you forget the update_run.sh file that came with this docker-compose.yml file?\" && exit 1 ; else chmod +x /tmp/update_run.sh && /tmp/update_run.sh && /etc/confluent/docker/run ; fi'"
Copy link
Contributor

Choose a reason for hiding this comment

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

@mbreevoort Can you please elaborate why this should be required? Shouldn't the permissions be inherited from the file, which should already be executable?

Copy link
Author

Choose a reason for hiding this comment

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

saved the files first, my bad. After checkout the repo it works... my bad. Keep up the good work removing zookeeper :-)

Copy link
Author

Choose a reason for hiding this comment

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

probably ${PWD} isn't needed either

Choose a reason for hiding this comment

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

@mbreevoort that mean your PR is no more necessary ?

@mbreevoort
Copy link
Author

@raphaelauv PR is not needed anymore, works as designed and will close this issue and PR

@mbreevoort mbreevoort closed this Nov 25, 2021
@dobrych
Copy link

dobrych commented Mar 11, 2022

If somebody else will come here searching why their update_run.sh is not visible to docker, problem is likely in SE Linux settings that prevent accessing files from within docker. Solution chcon -Rt svirt_sandbox_file_t /path/to/file

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