Skip to content

M1saka10010/lightsail-change-ip

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 

Repository files navigation

A simple lightsail ip changer

Notice

Running this script requires a server located in mainland China. This script is only valid when running in mainland China. It helps you protect your server from being blocked by GFW.

How to use

  1. Use git to clone this repo

    git clone https://github.com/m1saka10010/lightsail-change-ip.git

  2. Move into the directory

    cd lightsail-change-ip

  3. Install dependencies

    pip install -r requirements.txt

  4. Set up the aws-cli

    aws configure

  5. Edit the config in aws.py

# aws.py
region = "ap-southeast-1"  # Your region
# Your aws name (not username, it's the name of your lightsail instance)
awsName = "awsName"
ipName = "ipName"  # Your static ip name
port = 443  # Your server port
roundTime = 600  # Check interval
notifyOn = True  # Whether to notify you when ip changed
telegramBotKey = "telegramBotKey"  # Your telegram bot key
telegramChatId = "telegramChatId"  # Your telegram chat id
# Telegram bot api(you may proxy it if you are in China)
telegramBotApi = "https://api.telegram.org"
  1. Run the script

    python3 aws.py

About

A simple lightsail ip changer

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages