Git Product home page Git Product logo

azure_terraform_vm's Introduction

Nixos uses Terraform for Azure virtual machine creation


[Using Microsoft base example](https://learn.microsoft.com/en-us/azure/virtual-machines/linux/quick-create-terraform?tabs=azure-cli)


Using in Nixos environment:
  1. execute nix.shell to load Azure and Terraform commands

az login -> go through Azure login process in the opened web browser

  1. terraform init -upgrade

  2. terraform plan

  3. terraform apply



If VM creation was ok, local machine public key must be added to VM .ssh/authorized_keys file. Azure seems to want RSA keys. (dir and file protections chmod 700/600). Use Azure web UI portal to connect to the created machine via shell for this operation. Nano editor to create the file.

Log into new VM from local machine: ssh -v YOUR_AZURE_ACCOUNT@NEW_VM_IP_ADDRESS

Destroy VM (to stop possible billing):

  1. terraform plan -destroy
  2. terraform apply


NOTE: Check finally VM status via Azure WEBUI protal, you might have to stop(and delete) VM via the portal!!!

azure_terraform_vm's People

Contributors

mnokka-unikie avatar mnokka avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.