洛杉矶MC机房 高速低价18元起

DIYVM

[经验] 【宝塔】**已经修复0点BUG了,下个版*更新

提示:如果官网是英文页面,建议使用谷歌浏览器能同步翻译页面。点击下载【谷歌浏览器最新绿色便携版】
注意:部分文章发布时间较长,可能存在未知因素,购买时建议在本站搜索商家名称,先充分了解商家动态。
交流:唯一投稿邮箱:hostvps@88.com。

网友 imes 说:

*帖最后由 imes 于 2022-6-13 11:56 编辑

已经修复,等后续更新即可,已奖励宝塔币300,这三百个宝塔币不知道能干什么,有一半得归功于@fly*ie 不知道能不能分出去

附赠一个宝塔的邮件**程序,自带的mail**很烦人,用golang重写了命令,解压后chmod +x mail **放到/usr/bin/里,任意目录执行mail命令就能查看
算了,loc不能上传程序,就放源码吧
package main

import (
        &*uot;bytes&*uot;
        &*uot;fmt&*uot;
        &*uot;os/exec&*uot;
)

//function to execute linux shell command
func execCommand(command st**ng) (st**ng, er**r) {
        cmd := exec.Command(&*uot;/bin/sh&*uot;, &*uot;-c&*uot;, command)
        var out bytes.Buffer
        cmd.Stdout = &out
        err := cmd.Run()
        ret**n out.St**ng(), err
}

// main function
func main() {
        // output notice to user to chose command
        // if input is &*uot;check&*uot; then execute check command &*uot;cat /var/spool/mail/**ot&*uot;
        // elif input is &*uot;clean&*uot; then execute clean command &*uot;cat /dev/null > /var/spool/mail/**ot&*uot;
        // else exit
        p**ntln(&*uot;Please input command: check or clean&*uot;)
        var command st**ng
        _, err := fmt.Scanln(&command)
        if err != nil {
                p**ntln(&*uot;Er**r: &*uot; + err.Er**r())
                ret**n
        }
        if command == &*uot;check&*uot; {
                p**ntln(&*uot;Execute command: cat /var/spool/mail/**ot&*uot;)
                out, err := execCommand(&*uot;cat /var/spool/mail/**ot&*uot;)
                if err != nil {
                        p**ntln(&*uot;Er**r: &*uot; + err.Er**r())
                        ret**n
                }
                p**ntln(out)
        }
        if command == &*uot;clean&*uot; {
                p**ntln(&*uot;Execute command: cat /dev/null > /var/spool/mail/**ot&*uot;)
                out, err := execCommand(&*uot;cat /dev/null > /var/spool/mail/**ot&*uot;)
                if err != nil {
                        p**ntln(&*uot;Er**r: &*uot; + err.Er**r())
                        ret**n
                }
                p**ntln(out)
        }
        if command != &*uot;check&*uot; && command != &*uot;clean&*uot; {
                p**ntln(&*uot;Er**r: Invalid command&*uot;)
                ret**n
        }
}

网友 米老鼠 说:

这理由不错的


网友 thaizxj 说:

下个版*应该会修复能用第三方云平台的bug吧


网友 imes 说:

thaizxj 发表于 2022-6-13 11:33
下个版*应该会修复能用第三方云平台的bug吧
网友 kill 说:

好的,已卸载


网友 海的尽头 说:

现在没人关心了,都想尽快逃离


网友 imes 说:

海的尽头 发表于 2022-6-13 11:40
现在没人关心了,都想尽快逃离
网友 zxxx 说:

imes 发表于 2022-6-13 11:41
我在等AMH的新版*
网友 laianguo 说:

攒了两千多宝塔币  换了一个充电头。。不知道发货没有。,


网友 etc小号 说:

https://www.**.cn/integral

300宝塔币居然价值9天的企业版


网友 气味 说:

……看不懂

About 贝壳

【声明】:本博客不参与任何交易,也非中介,仅记录个人感兴趣的主机测评结果和优惠活动,内容均不作直接、间接、法定、约定的保证。访问本博客请务必遵守有关互联网的相关法律、规定与规则。一旦您访问本博客,即表示您已经知晓并接受了此声明通告。

 收藏 (0) 打赏

您可以选择一种方式赞助本站

支付宝扫一扫赞助

微信钱包扫描赞助

本文链接:贝壳主机网 » [经验] 【宝塔】**已经修复0点BUG了,下个版*更新

分享到: 生成海报
香港/美国/国内高速VPS
切换注册

登录

忘记密码 ?

切换登录

注册

我们将发送一封验证邮件至你的邮箱, 请正确填写以完成账号注册和激活