shell 命令行直接执行ok,但是挂到cron上就无法执行成功。
1:查看/var/log/cron
发现对应的定时任务是调度了,但是紧接着下面有一行提示
````
sendmail: fatal: parameter inet_interfaces: no local interface
```
2: /etc/postfix/main.cf
```
#inet_interfaces = localhost
#inet_protocols = localhost
inet_interfaces = all
inet_protocols = all
```
3:the input device is not a TTY
cron执行时去掉t参数
```
#docker exec -it afa70a46dbd4
#docker exec -i afa70a46dbd4
```