In [ ]:
%%bash
pull_force_overwrite_local
In [ ]:
!which pull_force_overwrite_local
In [ ]:
!ls -l /root/scripts/
In [ ]:
!cat /root/scripts/pull_force_overwrite_local
In [ ]:
%%html
<iframe width=800 height=600 src="http://pipeline.io"></iframe>
Please Star this GitHub Repo!!
Please Join this Global Meetup!!
In [ ]:
import requests
url = 'http://169.254.169.254/computeMetadata/v1/instance/network-interfaces/0/access-configs/0/external-ip'
headers = {'Metadata-Flavor': 'Google'}
r = requests.get(url, headers=headers)
ip_address = r.text
print('Your IP: %s' % ip_address)
In [ ]:
import requests
import json
url = 'http://allocator.demo.pipeline.io/allocation/%s' % ip_address
r = requests.get(url, timeout=5)
allocation = r.text
allocation_json = json.loads(allocation)
print(allocation_json)
print(allocation_json['index'])
In [ ]: