Giter VIP home page Giter VIP logo

noipy's People

Contributors

dependabot-preview[bot] avatar dependabot-support avatar dependabot[bot] avatar jayennis22 avatar pv8 avatar pyup-bot avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

noipy's Issues

Fix "Similar code" issue in noipy/authinfo.py

Similar code found in 1 other location (mass = 49):

        if not os.path.exists(config_location):
            print("Creating custom config directory [%s]... "
                  % config_location, end="")
            os.mkdir(config_location)
            print("OK.")
        if not os.path.exists(config_dir):
            print("Creating directory [%s]... " % config_dir, end="")
            os.mkdir(config_dir)
            print("OK.")

https://codeclimate.com/github/pv8/noipy/noipy/authinfo.py#issue_5730a7f49e33d10001076de8

Send update request only if IP has changed

Create a feature to avoid sending a new request to the DDNS provider if the machine external IP haven't changed since the last update. This is useful when noipy is scheduled to run periodically via crontab.

Tests failing with Python 3.2

Because virtualenv has dropped support for Python 3.2 on version 14.0.0, noipy building has been falling:

Traceback (most recent call last):
  File "<stdin>", line 7, in <module>
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv_support/pip-8.1.1-py2.py3-none-any.whl/pip/__init__.py", line 16, in <module>
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv_support/pip-8.1.1-py2.py3-none-any.whl/pip/vcs/mercurial.py", line 9, in <module>
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv_support/pip-8.1.1-py2.py3-none-any.whl/pip/download.py", line 36, in <module>
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv_support/pip-8.1.1-py2.py3-none-any.whl/pip/utils/ui.py", line 15, in <module>
py2.py3-none-any.whl/pip/_vendor/progress/bar.py", line 48
    empty_fill = u'โˆ™'
                      ^
SyntaxError: invalid syntax
----------------------------------------
...Installing setuptools, pip, wheel...done.
Traceback (most recent call last):
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv.py", line 2316, in <module>
    main()
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv.py", line 708, in main
    symlink=options.symlink)
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv.py", line 941, in create_environment
    download=download,
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv.py", line 897, in install_wheel
    call_subprocess(cmd, show_stdout=False, extra_env=env, stdin=SCRIPT)
  File "/home/travis/virtualenv/python2.7.9/lib/python2.7/site-packages/virtualenv.py", line 792, in call_subprocess
    % (cmd_desc, proc.returncode))
OSError: Command /home/travis/build/p...x/py32/bin/python3.2 - setuptools pip wheel failed with error code 1
Running virtualenv with interpreter /opt/python/3.2.5/bin/python3.2
ERROR: InvocationError: /home/travis/virtualenv/python2.7.9/bin/python -m virtualenv --python /opt/python/3.2.5/bin/python3.2 py32 (see /home/travis/build/pv8/noipy/.tox/py32/log/py32-0.log)
___________________________________ summary ____________________________________
ERROR:   py32: InvocationError: /home/travis/virtualenv/python2.7.9/bin/python -m virtualenv --python /opt/python/3.2.5/bin/python3.2 py32 (see /home/travis/build/pv8/noipy/.tox/py32/log/py32-0.log)
The command "tox -e $TOXENV" exited with 1.
store build cache
0.00s
10.77schange detected:
(dev).tmpl
/home/travis/build/pv8/noipy/.tox/dist/noipy-1.4.4.zip
/home/travis/build/pv8/noipy/.tox/log/tox-0.log
/home/travis/build/pv8/noipy/.tox/py27/bin/activate
/home/travis/build/pv8/noipy/.tox/py27/bin/activate.csh
/home/travis/build/pv8/noipy/.tox/py27/bin/activate.fish
/home/travis/build/pv8/noipy/.tox/py27/bin/activate_this.py
/home/travis/build/pv8/noipy/.tox/py27/bin/coverage
/home/travis/build/pv8/noipy/.tox/py27/bin/coverage2
/home/travis/build/pv8/noipy/.tox/py27/bin/coverage-2.7
/home/travis/build/pv8/noipy/.tox/py27/bin/easy_install
/home/travis/build/pv8/noipy/.tox/py27/bin/easy_install-2.7
/home/travis/build/pv8/noipy/.tox/py27/bin/noipy
/home/travis/build/pv8/noipy/.tox/py27/bin/pip
/home/travis/build/pv8/noipy/.tox/py27/bin/pip2
/home/travis/build/pv8/noipy/.tox/py27/bin/pip2.7
/home/travis/build/pv8/noipy/.tox/py27/bin/python
/home/travis/build/pv8/noipy/.tox/py27/bin/python2
/home/travis/build/pv8/noipy/.tox/py27/bin/python2.7
/home/travis/build/pv8/noipy/.tox/py2
...
changes detected, packing new archive
.
uploading archive
Done. Your build exited with 1.

Workaround it or drop support to Python 3.2 as well?

Example to run service via systemd

Hey, I think some people might found this useful:

Description=noip service
After=network.target
After=syslog.target

[Install]
WantedBy=multi-user.target

[Service]
ExecStart=noipy --provider noip --hostname <hostname>
Restart=always
Type=forking

You need to use --store as root, otherwise the service will fail to start.

Running it on Raspbian it started to produce this error a few weeks ago

Used to work well, I'm not sure what broke it.
OS: Raspbian GNU/Linux 10 (buster)
HW: Raspberry 4

Command line:
/usr/local/bin/noipy -u xxxxxx -p xxxxxx -n xxxxxx.ddns.net --provider noip

Result:

== noipy DDNS updater tool v1.5.2 ==
Traceback (most recent call last):
File "/usr/local/bin/noipy", line 10, in
sys.exit(main())
File "/usr/local/lib/python2.7/dist-packages/noipy/main.py", line 168, in main
result = execute_update(args)
File "/usr/local/lib/python2.7/dist-packages/noipy/main.py", line 111, in execute_update
ip_address = args.ip if args.ip else utils.get_ip()
File "/usr/local/lib/python2.7/dist-packages/noipy/utils.py", line 29, in get_ip
ip, _ = r.json()['origin'].split(',')
ValueError: need more than 1 value to unpack

Error when executing cmd line

Error when executing from command line passing username argument:

$ noipy -u <user> -p <password> -n <hostname> --provider <provider>

Error message:

AttributeError: 'Namespace' object has no attribute 'username'

auto generated props file

Implement a feature to generate the properties file via command line in order to make the usage of the tool even easier.

Improve plugins structure

Remove plugins from the project so they can be installed and loaded separately from noipy - i.e. Flask extensions structure.

Currently, plugins are specified inside dnsupdater.py file:

AVAILABLE_PLUGINS = {
'noip': 'NoipDnsUpdater',
'dyn': 'DynDnsUpdater',
'duck': 'DuckDnsUpdater',
'generic': 'GenericDnsUpdater',
}
DEFAULT_PLUGIN = 'generic'

Important: A good documentation on how to implement plugins need to be part of this improvement.

Containerize noipy

Containerize noipy so it is possible to isolate the environment where the tool runs.

Initial Update

Hi ๐Ÿ‘Š

This is my first visit to this fine repo, but it seems you have been working hard to keep all dependencies updated so far.

Once you have closed this issue, I'll create seperate pull requests for every update as soon as I find one.

That's it for now!

Happy merging! ๐Ÿค–

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.