Skip to content

Commit

Permalink
Store supports sub directories
Browse files Browse the repository at this point in the history
Fix for vagrant file

Remove errant comment in readme
  • Loading branch information
Richard Wellum committed Aug 4, 2016
1 parent 8607f95 commit 0a4bfaa
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
2 changes: 0 additions & 2 deletions README.rst
Expand Up @@ -21,8 +21,6 @@ economic benefit of using their existing laptop hardware.
Currently this supports IOS XRv (64-bit) only but will be adapted to
also handle `IOS XRv 9000`_ images.

Test for githooks

^^^^^^^^^^^^^^^^^^^^^^^^^
An IOS XRv (64-bit) VM:
^^^^^^^^^^^^^^^^^^^^^^^^^
Expand Down
8 changes: 6 additions & 2 deletions iosxr_store_box.py
Expand Up @@ -108,6 +108,8 @@ def main(argv):
help='Optionally specify a reason for uploading this box')
parser.add_argument('-r', '--release', action='store_true',
help="upload to '$ARTIFACTORY_LOCATION_RELEASE' rather than '$ARTIFACTORY_LOCATION_SNAPSHOT'.")
parser.add_argument('-s', '--sub_dir', dest='subdir', required=True,
help="subdirectory to upload to, e.g '6.1.1', 'stable'")
parser.add_argument('-v', '--verbose',
action='store_const', const=logging.DEBUG,
default=logging.INFO, help='turn on verbose messages')
Expand All @@ -123,6 +125,7 @@ def main(argv):
message = args.message
artifactory_release = args.release
test_only = args.test_only
subdir = args.subdir

if not input_box:
sys.exit('No input box detected, use -b to specify a box')
Expand All @@ -140,6 +143,7 @@ def main(argv):
logger.debug("Receiver is: '%s'" % receiver)
logger.debug("Release is: '%s'" % artifactory_release)
logger.debug("Test Only is: '%s'" % test_only)
logger.debug("Sub dir is: '%s'" % subdir)

'''
Copy the box to artifactory. This will most likely change to Atlas, or maybe both.
Expand All @@ -157,9 +161,9 @@ def main(argv):
"E.g.: export 'ARTIFACTORY_LOCATION_SNAPSHOT=http://location', or: \n"
"E.g.: export 'ARTIFACTORY_LOCATION_RELEASE=http://location'")

box_out = os.path.join(location, boxname)
box_out = os.path.join(location, subdir, boxname)
generate_hash(input_box)
hash_out = os.path.join(location, os.path.basename(hash_file))
hash_out = os.path.join(location, subdir, os.path.basename(hash_file))

if test_only is True:
logger.debug('Test only: copying %s to %s' % (input_box, box_out))
Expand Down
10 changes: 4 additions & 6 deletions vagrantfiles/simple-mixed-topo/Vagrantfile
Expand Up @@ -10,19 +10,19 @@ Vagrant.configure(2) do |config|
# Forward a port for grpc server access from the host, for eg. port 57777 configured on XR, forwarded to 57778 on host
node.vm.network :forwarded_port, guest: 57777, host: 57778, id: "grpc", auto_correct: true

# gig0/0/0/0 connected to link2, gig00/0/1 connected to link1, gig0/0/0/2 connected to link3, auto-config not supported.
node.vm.network :private_network, virtualbox__intnet: "link2", auto_config: false
# gig0/0/0/0 connected to link1, gig00/0/1 connected to link2, gig0/0/0/2 connected to link3, auto-config not supported.
node.vm.network :private_network, virtualbox__intnet: "link1", auto_config: false
node.vm.network :private_network, virtualbox__intnet: "link2", auto_config: false
node.vm.network :private_network, virtualbox__intnet: "link3", auto_config: false

end

config.vm.define "rtr2" do |node|
node.vm.box = "IOS XRv"

# gig0/0/0/0 connected to link1, gig0/0/0/1 connected to link3, auto-config not supported
# gig0/0/0/0 connected to link1, gig0/0/0/1 connected to link2, auto-config not supported
node.vm.network :private_network, virtualbox__intnet: "link1", auto_config: false
node.vm.network :private_network, virtualbox__intnet: "link3", auto_config: false
node.vm.network :private_network, virtualbox__intnet: "link2", auto_config: false

node.vm.provider "virtualbox" do |v|
# Optional, forward the XR console serial port a TCP port on the host
Expand All @@ -32,12 +32,10 @@ Vagrant.configure(2) do |config|
end
end


config.vm.define "devbox" do |node|
node.vm.box = "ubuntu/trusty64"

# eth1 connected to link2, auto_config is supported for an ubuntu instance
node.vm.network :private_network, virtualbox__intnet: "link2", ip: "11.1.1.2"

end
end

0 comments on commit 0a4bfaa

Please sign in to comment.