{"id":17282651,"url":"https://github.com/yi-tseng/onie-vagrant","last_synced_at":"2026-02-03T18:35:13.718Z","repository":{"id":152031374,"uuid":"314407125","full_name":"Yi-Tseng/onie-vagrant","owner":"Yi-Tseng","description":null,"archived":false,"fork":false,"pushed_at":"2020-11-20T00:50:30.000Z","size":24707,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2025-07-06T03:39:06.786Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":null,"has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/Yi-Tseng.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2020-11-20T00:48:57.000Z","updated_at":"2021-03-03T11:26:29.000Z","dependencies_parsed_at":null,"dependency_job_id":"9f30aa53-4523-4915-a174-36e9c15263a5","html_url":"https://github.com/Yi-Tseng/onie-vagrant","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/Yi-Tseng/onie-vagrant","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yi-Tseng%2Fonie-vagrant","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yi-Tseng%2Fonie-vagrant/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yi-Tseng%2Fonie-vagrant/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yi-Tseng%2Fonie-vagrant/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/Yi-Tseng","download_url":"https://codeload.github.com/Yi-Tseng/onie-vagrant/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/Yi-Tseng%2Fonie-vagrant/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29052635,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-03T15:43:47.601Z","status":"ssl_error","status_checked_at":"2026-02-03T15:43:46.709Z","response_time":96,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-10-15T09:49:17.651Z","updated_at":"2026-02-03T18:35:13.701Z","avatar_url":"https://github.com/Yi-Tseng.png","language":null,"funding_links":[],"categories":[],"sub_categories":[],"readme":"# ONIE Vagrant box\n\n## Tested with following tools\n\n- Vagrant 2.2.13\n- Packer 1.6.5\n- Socat 1.7.3.4\n\n## Build the box\n\n**You can skip this step if you want to use Vagrant box only.**\n\nTo build the Vagrant box, you need to first start a ONIE VM from ONIE iso image.\n\nYou can build the ONIE image from scratch or use the one provided in this repo.\n\nHere we use VirtualBox to start and install ONIE, below are some parameters for the VM\n\n- Name: onie\n- Type: Linux\n- Version: Other Linux (64-bit)\n- Memory size: Default, Can change later after install the NOS\n- Disk size: Default, depends on the size of NOS that will be install later\n- Storage\n  - The hard disk should be under SATA controller instead of IDE or else\n  - Add ONIE iso as a CD-ROM\n- Serial ports\n  - Enable Port 1\n  - Port Number: COM1\n  - IRQ, I/O Port: default\n  - Port Mode: TCP\n  - Check \"Connect to exisiting pipe/socket\"\n  - Path/Address: 127.0.0.1:8999 (can choose port you like)\n\nAfter VM created, we need to start a server so the serial port can use\n\nHere use use `socat` tool to create a server.\n\n```bash\nsocat file:`tty`,raw,echo=0 tcp-listen:8999\n```\n\nAfter socat started, we can start the VM, and you shoud be able to see the GRUB UI from the terminal that socat is running.\n\n![GRUB](imgs/GRUB.png)\n\nGo to `ONIE: Embed ONIE` to install the ONIE.\n\nThis shoud takes few minuts, you can shutdown the VM when you see `Post installation hook`. The ONIE will keep installing again and again if you don't do anything.\n\nUse `halt` command to halt the system, turn off the VM when you see `reboot: System halted`\n\nNow you should remove the ONIE installer iso to prevent the VN booting from it.\n\nYou also need to remove the serial port setting since we don't need it when we pack it using packer.\n\nAfter these process, we are ready to pack the VM as a Vagrant box.\n\n```bash\npacker build onie-vm.json\n```\n\nAfter build, you will get a new file in this directory called `packer_virtualbox-vm_virtualbox.box`\n\nAnd you should be able to add the box by using the command:\n\n```bash\nvagrant box add ./packer_virtualbox-vm_virtualbox.box\n```\n\n## To use the ONIE box\n\nBy default, the system will enter ONIE install mode, which provide ssh access.\n\nHowever, most of installers(e.g., ONL) requires using the console, so in Vagrantfile there\nis a setting which enable the console/serial port.\n\nStart the socat before start the VM\n\n```bash\nsocat file:`tty`,raw,echo=0 tcp-listen:8999\n```\n\nAfter socat started, use `vagrant up` to start the VM.\n\nAnd you will be able to access the GRUB and ONIE from the terminal that starts the socat.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyi-tseng%2Fonie-vagrant","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fyi-tseng%2Fonie-vagrant","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fyi-tseng%2Fonie-vagrant/lists"}