Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
R
re6stnet
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Boris Kocherov
re6stnet
Commits
8df410f7
Commit
8df410f7
authored
Dec 29, 2015
by
Julien Muchembled
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Use python2 instead python and fix install for a custom Python interpreter
parent
9f01d5d1
Changes
14
Show whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
34 additions
and
14 deletions
+34
-14
Makefile
Makefile
+4
-2
daemon/network-manager
daemon/network-manager
+1
-1
debian/common.mk
debian/common.mk
+2
-1
debian/rules
debian/rules
+3
-0
demo/demo
demo/demo
+1
-1
draft/re6st-cn
draft/re6st-cn
+1
-1
draft/re6st-geo
draft/re6st-geo
+1
-1
re6st/cli/conf.py
re6st/cli/conf.py
+1
-1
re6st/cli/node.py
re6st/cli/node.py
+1
-1
re6st/cli/registry.py
re6st/cli/registry.py
+1
-1
re6st/ovpn-client
re6st/ovpn-client
+1
-1
re6st/ovpn-server
re6st/ovpn-server
+1
-1
re6stnet.spec
re6stnet.spec
+1
-1
setup.py
setup.py
+15
-1
No files found.
Makefile
View file @
8df410f7
...
@@ -17,12 +17,14 @@ install: install-noinit
...
@@ -17,12 +17,14 @@ install: install-noinit
done
done
install-noinit
:
install-man
install-noinit
:
install-man
install
-Dp
daemon/network-manager
$(DESTDIR)$(NM)
set
-e
$(DESTDIR)$(PREFIX)
/bin/re6stnet
;
[
-x
$$
1
$$
2
]
||
\
set
-e
$(DESTDIR)$(PREFIX)
/bin/re6stnet
;
[
-x
$$
1
$$
2
]
||
\
python2.7 setup.py
install
--prefix
=
$(PREFIX)
--root
=
$(DESTDIR)
;
\
$(
or
$(PYTHON)
,python2
)
setup.py
install
\
--prefix
=
$(PREFIX)
--root
=
$(DESTDIR)
;
\
$(
and
$(PYTHON)
,sed
-ri
'1s:^#!\S+:#!
$(PYTHON)
:'
$(DESTDIR)$(NM)
;
)
\
install
-d
$$
1/sbin
;
mv
$$
1
$$
2
$$
1/sbin
install
-d
$$
1/sbin
;
mv
$$
1
$$
2
$$
1/sbin
install
-Dpm
0644 daemon/README.conf
$(DESTDIR)
/etc/re6stnet/README
install
-Dpm
0644 daemon/README.conf
$(DESTDIR)
/etc/re6stnet/README
install
-Dpm
0644 daemon/logrotate.conf
$(DESTDIR)
/etc/logrotate.d/re6stnet
install
-Dpm
0644 daemon/logrotate.conf
$(DESTDIR)
/etc/logrotate.d/re6stnet
install
-Dp
daemon/network-manager
$(DESTDIR)$(NM)
install-man
:
$(MANPAGELIST)
install-man
:
$(MANPAGELIST)
set
-e
;
for
x
in
$^
;
\
set
-e
;
for
x
in
$^
;
\
...
...
daemon/network-manager
View file @
8df410f7
#!/usr/bin/python -S
#!/usr/bin/python
2
-S
import
errno
,
glob
,
os
,
signal
,
socket
,
subprocess
,
sys
,
time
import
errno
,
glob
,
os
,
signal
,
socket
,
subprocess
,
sys
,
time
DAEMON
=
"re6stnet"
DAEMON
=
"re6stnet"
...
...
debian/common.mk
View file @
8df410f7
...
@@ -18,7 +18,8 @@ debian/changelog:
...
@@ -18,7 +18,8 @@ debian/changelog:
endif
endif
override_dh_install
:
override_dh_install
:
make
DESTDIR
=
$(TMP)
PREFIX
=
/usr install-noinit install-ifupdown
make
DESTDIR
=
$(TMP)
PREFIX
=
/usr
PYTHON
=
/usr/bin/python
\
install-noinit install-ifupdown
override_dh_installinit
:
override_dh_installinit
:
install
-d
$(INIT)
install
-d
$(INIT)
...
...
debian/rules
View file @
8df410f7
...
@@ -15,5 +15,8 @@ override_dh_python2:
...
@@ -15,5 +15,8 @@ override_dh_python2:
override_dh_auto_clean
:
override_dh_auto_clean
:
make clean
make clean
# Do not build twice ('setup.py install' builds automatically)
override_dh_auto_build
:
%
:
%
:
dh
$@
--with
python2
--buildsystem
=
python_distutils
dh
$@
--with
python2
--buildsystem
=
python_distutils
demo/demo
View file @
8df410f7
#!/usr/bin/python
#!/usr/bin/python
2
import math, nemu, os, re, signal, socket, subprocess, sys, time, weakref
import math, nemu, os, re, signal, socket, subprocess, sys, time, weakref
from collections import defaultdict
from collections import defaultdict
IPTABLES = 'iptables'
IPTABLES = 'iptables'
...
...
draft/re6st-cn
View file @
8df410f7
#!/usr/bin/python
#!/usr/bin/python
2
import
sqlite3
,
sys
import
sqlite3
,
sys
if
're6st'
not
in
sys
.
modules
:
if
're6st'
not
in
sys
.
modules
:
import
os
;
sys
.
path
[
0
]
=
os
.
path
.
dirname
(
sys
.
path
[
0
])
import
os
;
sys
.
path
[
0
]
=
os
.
path
.
dirname
(
sys
.
path
[
0
])
...
...
draft/re6st-geo
View file @
8df410f7
#!/usr/bin/python
#!/usr/bin/python
2
# -*- coding: utf-8 -*-
# -*- coding: utf-8 -*-
import
argparse
,
httplib
,
select
,
socket
,
sqlite3
,
struct
,
sys
,
time
,
traceback
import
argparse
,
httplib
,
select
,
socket
,
sqlite3
,
struct
,
sys
,
time
,
traceback
import
xml.etree.cElementTree
as
ET
import
xml.etree.cElementTree
as
ET
...
...
re6st/cli/conf.py
View file @
8df410f7
#!/usr/bin/python
#!/usr/bin/python
2
import
argparse
,
atexit
,
binascii
,
errno
,
hashlib
import
argparse
,
atexit
,
binascii
,
errno
,
hashlib
import
os
,
subprocess
,
sqlite3
,
sys
,
time
import
os
,
subprocess
,
sqlite3
,
sys
,
time
from
OpenSSL
import
crypto
from
OpenSSL
import
crypto
...
...
re6st/cli/node.py
View file @
8df410f7
#!/usr/bin/python
#!/usr/bin/python
2
import
atexit
,
errno
,
logging
,
os
,
shutil
,
signal
import
atexit
,
errno
,
logging
,
os
,
shutil
,
signal
import
socket
,
struct
,
subprocess
,
sys
,
time
,
threading
import
socket
,
struct
,
subprocess
,
sys
,
time
,
threading
from
collections
import
deque
from
collections
import
deque
...
...
re6st/cli/registry.py
View file @
8df410f7
#!/usr/bin/python
#!/usr/bin/python
2
import
httplib
,
logging
,
os
,
socket
,
sys
import
httplib
,
logging
,
os
,
socket
,
sys
from
BaseHTTPServer
import
BaseHTTPRequestHandler
from
BaseHTTPServer
import
BaseHTTPRequestHandler
from
SocketServer
import
ThreadingTCPServer
from
SocketServer
import
ThreadingTCPServer
...
...
re6st/ovpn-client
View file @
8df410f7
#!/usr/bin/python -S
#!/usr/bin/python
2
-S
import
os
,
sys
import
os
,
sys
script_type
=
os
.
environ
[
'script_type'
]
script_type
=
os
.
environ
[
'script_type'
]
...
...
re6st/ovpn-server
View file @
8df410f7
#!/usr/bin/python -S
#!/usr/bin/python
2
-S
import
os
,
sys
import
os
,
sys
script_type
=
os
.
environ
[
'script_type'
]
script_type
=
os
.
environ
[
'script_type'
]
...
...
re6stnet.spec
View file @
8df410f7
%define _builddir %(pwd)
%define _builddir %(pwd)
%define ver %(python re6st/version.py)
%define ver %(python
2
re6st/version.py)
%define units re6stnet.service re6st-registry.service
%define units re6stnet.service re6st-registry.service
Summary: resilient, scalable, IPv6 network application
Summary: resilient, scalable, IPv6 network application
...
...
setup.py
View file @
8df410f7
"""Resilient, Scalable, IPv6 Network
"""Resilient, Scalable, IPv6 Network
"""
"""
import
os
,
stat
from
distutils.command.build_scripts
import
first_line_re
from
setuptools
import
setup
,
find_packages
from
setuptools
import
setup
,
find_packages
from
setuptools.command
import
sdist
as
_sdist
,
build_py
as
_build_py
from
setuptools.command
import
sdist
as
_sdist
,
build_py
as
_build_py
from
distutils
import
log
from
distutils
import
log
...
@@ -17,6 +18,19 @@ def copy_file(self, infile, outfile, *args, **kw):
...
@@ -17,6 +18,19 @@ def copy_file(self, infile, outfile, *args, **kw):
if
not
x
[
0
].
startswith
(
"_"
):
if
not
x
[
0
].
startswith
(
"_"
):
f
.
write
(
"%s = %r
\
n
"
%
x
)
f
.
write
(
"%s = %r
\
n
"
%
x
)
return
outfile
,
1
return
outfile
,
1
elif
isinstance
(
self
,
build_py
)
and
\
os
.
stat
(
infile
).
st_mode
&
stat
.
S_IEXEC
:
# Adjust interpreter of OpenVPN hooks.
with
open
(
infile
)
as
src
:
first_line
=
src
.
readline
()
m
=
first_line_re
.
match
(
first_line
)
if
m
and
not
self
.
dry_run
:
log
.
info
(
"copying and adjusting %s -> %s"
,
infile
,
outfile
)
executable
=
self
.
distribution
.
command_obj
[
'build'
].
executable
with
open
(
outfile
,
"wb"
)
as
dst
:
dst
.
write
(
"#!%s%s
\
n
"
%
(
executable
,
m
.
group
(
1
)
or
''
))
dst
.
write
(
src
.
read
())
return
outfile
,
1
cls
,
=
self
.
__class__
.
__bases__
cls
,
=
self
.
__class__
.
__bases__
return
cls
.
copy_file
(
self
,
infile
,
outfile
,
*
args
,
**
kw
)
return
cls
.
copy_file
(
self
,
infile
,
outfile
,
*
args
,
**
kw
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment