mirror of
https://github.com/SystemRage/py-kms.git
synced 2024-11-25 01:35:38 +01:00
Added IPv6 support (#73)
* Added IPv6 support * Updated docker images to IPv6 usage * Reverted commented entry point from testing. Sry.
This commit is contained in:
parent
3d203cbe1d
commit
9d9a3639e1
@ -2,7 +2,7 @@
|
||||
|
||||
FROM alpine:3.8
|
||||
|
||||
ENV IP 0.0.0.0
|
||||
ENV IP ::
|
||||
ENV PORT 1688
|
||||
ENV EPID ""
|
||||
ENV LCID 1033
|
||||
|
@ -9,8 +9,8 @@ FROM alpine:3.8
|
||||
|
||||
# EN: IP-address
|
||||
# RU: IP-адрес
|
||||
ENV IP 0.0.0.0
|
||||
# The IP address to listen on. The default is "0.0.0.0" (all interfaces).
|
||||
ENV IP ::
|
||||
# The IP address to listen on. The default is "::" (all interfaces).
|
||||
|
||||
# EN: TCP-port
|
||||
# RU: TCP-порт
|
||||
@ -115,4 +115,4 @@ WORKDIR /home/py-kms
|
||||
EXPOSE ${PORT}/tcp
|
||||
|
||||
# Entry point
|
||||
ENTRYPOINT ["/usr/bin/start.sh"]
|
||||
ENTRYPOINT ["/usr/bin/start.sh"]
|
||||
|
@ -36,6 +36,7 @@ class KeyServer(socketserver.ThreadingMixIn, socketserver.TCPServer):
|
||||
allow_reuse_address = True
|
||||
|
||||
def __init__(self, server_address, RequestHandlerClass):
|
||||
self.address_family = socket.AF_INET6 # This call make sure the server creates an IPv6 socket and NOT an IPv4 by default
|
||||
socketserver.TCPServer.__init__(self, server_address, RequestHandlerClass)
|
||||
self.__shutdown_request = False
|
||||
self.r_service, self.w_service = os.pipe()
|
||||
|
Loading…
Reference in New Issue
Block a user