RayWangQvQ / sing-box-installer

基于docker一键安装sing-box服务端,并自动生成vmess、naiveproxy、hysteria2节点
289 stars 74 forks source link

报错,是不是entry.sh和config.json文件有问题? #1

Closed JasonJasonXU closed 1 year ago

JasonJasonXU commented 1 year ago

都是从参考配置文件copy过来的

/# docker logs sing-box : invalid optionline 2: set: - set: usage: set [-abefhkmnptuvxBCEHPT] [-o option-name] [--] [-] [arg ...] /data/entry.sh: line 3: $'\r': command not found /data/entry.sh: line 6: $'\r': command not found entry Error: unknown command "version\r" for "sing-box"

Did you mean this? version

Run 'sing-box --help' for usage. FATAL[0000] unknown command "version\r" for "sing-box"

Did you mean this? version /data/entry.sh: line 9: $'\r': command not found

config: : no such file or directoryen /data/config.json ': No such file or directoryg.json Error: unknown shorthand flag: '\r' in - Usage: sing-box format [flags]

Flags: -h, --help help for format -w, --write write result to (source) file instead of stdout

Global Flags: -c, --config string set configuration file path (default "config.json") -D, --directory string set working directory --disable-color disable color output

FATAL[0000] unknown shorthand flag: '\r' in - ': No such file or directoryg.json /data/entry.sh: line 15: $'\r': command not found

starting : no such file or directoryen /data/config.json ': No such file or directory-box.json tail: no files : invalid optionline 2: set: - set: usage: set [-abefhkmnptuvxBCEHPT] [-o option-name] [--] [-] [arg ...] /data/entry.sh: line 3: $'\r': command not found /data/entry.sh: line 6: $'\r': command not found entry Error: unknown command "version\r" for "sing-box"

Did you mean this? version

Run 'sing-box --help' for usage. FATAL[0000] unknown command "version\r" for "sing-box"

Did you mean this? version /data/entry.sh: line 9: $'\r': command not found

config: : no such file or directoryen /data/config.json ': No such file or directoryg.json Error: unknown shorthand flag: '\r' in - Usage: sing-box format [flags]

Flags: -h, --help help for format -w, --write write result to (source) file instead of stdout

Global Flags: -c, --config string set configuration file path (default "config.json") -D, --directory string set working directory --disable-color disable color output

FATAL[0000] unknown shorthand flag: '\r' in - ': No such file or directoryg.json /data/entry.sh: line 15: $'\r': command not found

starting : no such file or directoryen /data/config.json ': No such file or directory-box.json tail: no files : invalid optionline 2: set: - set: usage: set [-abefhkmnptuvxBCEHPT] [-o option-name] [--] [-] [arg ...] /data/entry.sh: line 3: $'\r': command not found /data/entry.sh: line 6: $'\r': command not found entry Error: unknown command "version\r" for "sing-box"

Did you mean this? version

Run 'sing-box --help' for usage. FATAL[0000] unknown command "version\r" for "sing-box"

Did you mean this? version /data/entry.sh: line 9: $'\r': command not found

config: : no such file or directoryen /data/config.json ': No such file or directoryg.json Error: unknown shorthand flag: '\r' in - Usage: sing-box format [flags]

Flags: -h, --help help for format -w, --write write result to (source) file instead of stdout

Global Flags: -c, --config string set configuration file path (default "config.json") -D, --directory string set working directory --disable-color disable color output

FATAL[0000] unknown shorthand flag: '\r' in - ': No such file or directoryg.json /data/entry.sh: line 15: $'\r': command not found

starting : no such file or directoryen /data/config.json ': No such file or directory-box.json tail: no files : invalid optionline 2: set: - set: usage: set [-abefhkmnptuvxBCEHPT] [-o option-name] [--] [-] [arg ...] /data/entry.sh: line 3: $'\r': command not found /data/entry.sh: line 6: $'\r': command not found entry Error: unknown command "version\r" for "sing-box"

Did you mean this? version

Run 'sing-box --help' for usage. FATAL[0000] unknown command "version\r" for "sing-box"

Did you mean this? version /data/entry.sh: line 9: $'\r': command not found

config: : no such file or directoryen /data/config.json ': No such file or directoryg.json Error: unknown shorthand flag: '\r' in - Usage: sing-box format [flags]

Flags: -h, --help help for format -w, --write write result to (source) file instead of stdout

Global Flags: -c, --config string set configuration file path (default "config.json") -D, --directory string set working directory --disable-color disable color output

FATAL[0000] unknown shorthand flag: '\r' in - ': No such file or directoryg.json /data/entry.sh: line 15: $'\r': command not found

starting : no such file or directoryen /data/config.json ': No such file or directory-box.json tail: no files : invalid optionline 2: set: - set: usage: set [-abefhkmnptuvxBCEHPT] [-o option-name] [--] [-] [arg ...] /data/entry.sh: line 3: $'\r': command not found /data/entry.sh: line 6: $'\r': command not found entry Error: unknown command "version\r" for "sing-box"

Did you mean this? version

Run 'sing-box --help' for usage. FATAL[0000] unknown command "version\r" for "sing-box"

Did you mean this? version /data/entry.sh: line 9: $'\r': command not found

config: : no such file or directoryen /data/config.json ': No such file or directoryg.json Error: unknown shorthand flag: '\r' in - Usage: sing-box format [flags]

Flags: -h, --help help for format -w, --write write result to (source) file instead of stdout

Global Flags: -c, --config string set configuration file path (default "config.json") -D, --directory string set working directory --disable-color disable color output

FATAL[0000] unknown shorthand flag: '\r' in - ': No such file or directoryg.json /data/entry.sh: line 15: $'\r': command not found

starting : no such file or directoryen /data/config.json ': No such file or directory-box.json tail: no files : invalid optionline 2: set: - set: usage: set [-abefhkmnptuvxBCEHPT] [-o option-name] [--] [-] [arg ...] /data/entry.sh: line 3: $'\r': command not found entry /data/entry.sh: line 6: $'\r': command not found Error: unknown command "version\r" for "sing-box"

Did you mean this? version

Run 'sing-box --help' for usage. FATAL[0000] unknown command "version\r" for "sing-box"

Did you mean this? version /data/entry.sh: line 9: $'\r': command not found

config: : no such file or directoryen /data/config.json ': No such file or directoryg.json Error: unknown shorthand flag: '\r' in - Usage: sing-box format [flags]

Flags: -h, --help help for format -w, --write write result to (source) file instead of stdout

Global Flags: -c, --config string set configuration file path (default "config.json") -D, --directory string set working directory --disable-color disable color output

FATAL[0000] unknown shorthand flag: '\r' in - ': No such file or directoryg.json /data/entry.sh: line 15: $'\r': command not found

starting : no such file or directoryen /data/config.json ': No such file or directory-box.json tail: no files

RayWangQvQ commented 1 year ago

编码问题,有windows换行符,用vim拷贝进入或者用vim编辑下再wq试试。

JasonJasonXU commented 1 year ago

搞定,谢谢