{"id":20697456,"url":"https://github.com/epomatti/azure-vm-cni","last_synced_at":"2026-05-07T02:35:59.198Z","repository":{"id":212013374,"uuid":"729705248","full_name":"epomatti/azure-vm-cni","owner":"epomatti","description":"Azure CNI from a Virtual Machine containerized app","archived":false,"fork":false,"pushed_at":"2023-12-31T00:39:30.000Z","size":25,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-01-17T18:34:54.846Z","etag":null,"topics":["azure","azure-cni","azure-security","cni","cni-plugin","docker","go","golang","service-endpoint","service-endpoints","terraform"],"latest_commit_sha":null,"homepage":"","language":"HCL","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/epomatti.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":"2023-12-10T04:36:38.000Z","updated_at":"2023-12-31T19:49:24.000Z","dependencies_parsed_at":"2023-12-31T00:32:59.418Z","dependency_job_id":"99300ed3-39c7-4b7f-b64c-6eb8887dbff5","html_url":"https://github.com/epomatti/azure-vm-cni","commit_stats":null,"previous_names":["epomatti/azure-vm-cni"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/epomatti%2Fazure-vm-cni","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/epomatti%2Fazure-vm-cni/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/epomatti%2Fazure-vm-cni/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/epomatti%2Fazure-vm-cni/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/epomatti","download_url":"https://codeload.github.com/epomatti/azure-vm-cni/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":242961747,"owners_count":20213315,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","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":["azure","azure-cni","azure-security","cni","cni-plugin","docker","go","golang","service-endpoint","service-endpoints","terraform"],"created_at":"2024-11-17T00:18:07.313Z","updated_at":"2026-05-07T02:35:54.179Z","avatar_url":"https://github.com/epomatti.png","language":"HCL","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Azure VM CNI\n\nEnabling containers to use Azure Virtual Network capabilities with [Azure CNI][1] and Azure Virtual Machines.\n\n\u003e 💡 The documentation implies that CNI is required for containers to use Virtual Network capabilities, however, after finishing this project I discovered that CNI was not required to use Service Endpoints from a Virtual Machine. Maybe it is already installed or something, did not investigate.\n\n## Azure deploy\n\nSet the `.auto.tfvars` file:\n\n```sh\ncp config/template.tfvars .auto.tfvars\n```\n\nCreate the infrastructure:\n\n```sh\nterraform init\nterraform apply -auto-approve\n```\n\nConfirm that `cloud-init` has complete successfully.\n\nManually select the Service Endpoint Policy as it was having circular dependency issues.\n\nConnect via SSH to the virtual machine.\n\nRun the command to star the app container:\n\n```sh\nsudo docker run -p 8080:8080 \\\n    -e 'MSSQL_HOSTNAME=sqls-cni.database.windows.net' \\\n    -e 'MSSQL_PORT=1433' \\\n    -e 'MSSQL_USERNAME=dbadmin' \\\n    -e 'MSSQL_PASSWORD=P4ssw0rd!2023' \\\n    epomatti/azure-vm-cni-app:arm64\n```\n\nTeste the database connection:\n\n```sh\ncurl \u003cvm-ipaddress\u003e:8080/query\n```\n\n## Local development\n\nSet the `.env` file.\n\nStart the database:\n\n```sh\ndocker run -p 1433:1433 -e ACCEPT_EULA=Y -e SA_PASSWORD=P@ssw0rd.123 mcr.microsoft.com/mssql/server:2022-latest\n```\n\nRun the application:\n\n```sh\ncd app\n\ngo run .\n```\n\n[1]: https://learn.microsoft.com/en-us/azure/virtual-network/container-networking-overview\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fepomatti%2Fazure-vm-cni","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fepomatti%2Fazure-vm-cni","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fepomatti%2Fazure-vm-cni/lists"}