blob: 5346df63e73e82864af2af97f3bb56a6f26ed20a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
|
#!/usr/bin/env python
import os
from klein import run, route, resource
import soledad_sync as sync
@route('/start-sync')
def home(request):
print "GOT REQUEST FOR STARTING SYNC..."
d = sync.upload_soledad_stuff()
return d
@route('/ping')
def ping(request):
return 'easy!'
@route('/pid')
def pid(request):
return str(os.getpid())
if __name__ == "__main__":
#s = sync._get_soledad_instance_from_uuid(
#sync.UUID, 'pass', '/tmp/soledadsync', sync.HOST, '', '')
run("localhost", 8080)
|