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

[ISSUE #3370] Issue with executing shell script /bin/sh^M on Unix/Linux #3371

Merged
merged 4 commits into from
Jul 20, 2020

Conversation

Veryfirefly
Copy link
Contributor

Please do not create a Pull Request without creating an issue first.

What is the purpose of the change

  1. Fixed the /bin/sh^M problem when executing startup.sh and shutdown.sh scripts on Linux.
  2. Fixed the following problems when performing binary packaging: ERROR OS = Windows, and the assembly descriptor contains *nix specific root-relative-reference

Brief changelog

Path Change
nacos/distribution/bin/startup.sh CRLF -> LF
nacos/distribution/bin/shutdown.sh CRLF -> LF
nacos/distribution/release-nacos.xml nacos-server/outputDirectory

@Veryfirefly Veryfirefly changed the title [ISSUE #3370] ssue with executing shell script /bin/sh^M on Unix/Linux [ISSUE #3370] Issue with executing shell script /bin/sh^M on Unix/Linux Jul 18, 2020
@KomachiSion
Copy link
Collaborator

  1. I check the develop branch, the four bin files is LF already. I think we have no need to change.
  2. the nacos-server/outputDirectory, It has been able to run well, I do not know why it needs to be modified.

@Veryfirefly
Copy link
Contributor Author

  1. I check the develop branch, the four bin files is LF already. I think we have no need to change.
  2. the nacos-server/outputDirectory, It has been able to run well, I do not know why it needs to be modified.

The nacos-server/outputDirectory, The following error occurs when packaging: [ERROR] OS=Windows and the assembly descriptor contains a *nix-specific root-relative-reference (starting with slash) /target/. But this does not affect the packaging. This will give the developer an error message, similar to warning

I queried the documentation and found that the reason is: because the assembly task is executed on Windows, but it contains a path relative to Linux. The document states that outputDirectory defines a / which would in consequence mean to extract all contens to always same location.

This is my image when packing
OS=Windows

@KomachiSion KomachiSion added help wanted Extra attention is needed os/windows labels Jul 18, 2020
@KomachiSion
Copy link
Collaborator

KomachiSion commented Jul 18, 2020

My env is MacOs, has no error.

Can someone in the community help to confirm whether this change can eliminate the error message and be packaged correctly on windows OS?

@Veryfirefly
Copy link
Contributor Author

My env is MacOs, has no error.

Can someone in the community help to confirm whether this change can eliminate the error message and be packaged correctly on windows OS?

Ok i am looking for help

@zongtanghu
Copy link
Collaborator

image

@zongtanghu
Copy link
Collaborator

I have already verified this in my local windows enviroment.The result is as above.

@zongtanghu
Copy link
Collaborator

And If no anything modified, the result is as below:

image

@KomachiSion KomachiSion added kind/enhancement Category issues or prs related to enhancement. and removed help wanted Extra attention is needed labels Jul 20, 2020
@KomachiSion KomachiSion added this to the 1.3.2 milestone Jul 20, 2020
@KomachiSion KomachiSion merged commit 5eb7d6a into alibaba:develop Jul 20, 2020
@KomachiSion KomachiSion linked an issue Jul 20, 2020 that may be closed by this pull request
@Veryfirefly
Copy link
Contributor Author

And If no anything modified, the result is as below:

image

Thanks for help

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/enhancement Category issues or prs related to enhancement. os/windows
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Issue with executing shell script /bin/sh^M on Unix/Linux
3 participants