Skip to content

Provide execute permissions to docker-entrypoint.sh#465

Open
sahandilshan wants to merge 1 commit intowso2:masterfrom
sahandilshan:master
Open

Provide execute permissions to docker-entrypoint.sh#465
sahandilshan wants to merge 1 commit intowso2:masterfrom
sahandilshan:master

Conversation

@sahandilshan
Copy link
Copy Markdown

Purpose

Fix #463

@AnuradhaSK AnuradhaSK requested a review from Copilot July 7, 2025 15:03
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR ensures the entrypoint script is executable before container start to address a permission error.

  • Added a chmod +x command for the docker-entrypoint.sh file.
  • Updated the entrypoint definition remains unchanged but now relies on explicit permissions.

EXPOSE 4000 9763 9443

# Provide execute permissions to docker-entrypoint.sh
RUN chmod +x /home/wso2carbon/docker-entrypoint.sh
Copy link

Copilot AI Jul 7, 2025

Choose a reason for hiding this comment

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

[nitpick] Use the WORKING_DIRECTORY environment variable instead of hardcoding the path to improve consistency, e.g., RUN chmod +x ${WORKING_DIRECTORY}/docker-entrypoint.sh.

Suggested change
RUN chmod +x /home/wso2carbon/docker-entrypoint.sh
RUN chmod +x ${WORKING_DIRECTORY}/docker-entrypoint.sh

Copilot uses AI. Check for mistakes.
Comment on lines +134 to +135
RUN chmod +x /home/wso2carbon/docker-entrypoint.sh

Copy link

Copilot AI Jul 7, 2025

Choose a reason for hiding this comment

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

Consider setting execute permissions during the COPY step using --chmod=+x (Docker 18.09+) to reduce image layers, e.g., COPY --chmod=+x docker-entrypoint.sh ${WORKING_DIRECTORY}/.

Suggested change
RUN chmod +x /home/wso2carbon/docker-entrypoint.sh

Copilot uses AI. Check for mistakes.
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.

Error while starting a container from alpine dockerfile

3 participants