Giter Site home page Giter Site logo

dnspod-ddns's Introduction

dnspod-ddns

通过dnspod来进行ddns的小脚本,用来做什么,你懂得,本来不想写的,只是github.com另外一个哥们儿用py写的跑不起来,看了下代码有问题,懒得修改直接用golang撸了一个

如果对你有用,可以star一下,2333

使用

配置项:

配置采用环境变量驱动,具体见下:

# 填写你在dnspod申请的id
DNSPOD_ID=123456
# 在dnspod申请的token
DNSPOD_TOKEN=123456
# 在dnspod要更新的顶级域名
DNSPOD_DOMAIN=example.com
# 在dnspod要更新的子域名前缀,如果是根域名,填写@即可
DNSPOD_SUBDOMAIN=example
# 你的邮箱
DNSPOD_EMAIL[email protected]

docker运行

docker run --name=ddns --restart=always -d \
    -e DNSPOD_ID=${DNSPOD_ID} \
    -e DNSPOD_TOKEN=${DNSPOD_TOKEN} \
    -e DNSPOD_DOMAIN=${DNSPOD_DOMAIN} \
    -e DNSPOD_SUBDOMAIN=${DNSPOD_SUBDOMAIN} \
    -e [email protected] \
    scofieldpeng/dnspod-ddns:1.0.0

源码编译

  1. 安装go
  2. 下载源码
go get github.com/scofieldpeng/dnspod-ddns
  1. 编译
go build -o app .

$GOPATH/src/github.com/scofieldpeng/dnspod-ddns/app文件即为二进制包,直接运行即可

申请dnspod的ID和token

教程详见dnspod官网https://support.dnspod.cn/Kb/showarticle/tsid/227/

dnspod-ddns's People

Contributors

scofieldpeng avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.