Automation - #4 - Custom Script Extension

Поделиться
HTML-код
  • Опубликовано: 28 ноя 2024

Комментарии • 24

  • @rohansank7124
    @rohansank7124 3 года назад +1

    Thank you man ..you be saving lot of people

  • @cartierin
    @cartierin 5 лет назад +3

    This is great!! Is it possible to create one video related to azure private link. I am aware of service endpoint and policies. It would be nice to see some use cases related private link.

    • @AzureAcademy
      @AzureAcademy  5 лет назад +2

      Thanks for the feedback! We are working on endpoint policy and private link...stay tuned.

  • @jameseduard2092
    @jameseduard2092 2 года назад +1

    awesome guide, thank you so much, anyway do you have any guide how to deploy vm with terraform with custom script extension to install specific apps?

    • @AzureAcademy
      @AzureAcademy  2 года назад +1

      I don’t have any terraform stuff public yet but I am partnering with a few folks to get it out there
      Besides installing apps and deploying azure resources what else do you want to see

  • @errorcode9398
    @errorcode9398 4 года назад +1

    many thanks for help

  • @aniketbhise4680
    @aniketbhise4680 2 года назад +1

    will you tell me how to run a batch file in azure VMS at the scheduled time? time could be on-demand or recurrent and these all inputs are to that VMS came from local machin

    • @AzureAcademy
      @AzureAcademy  2 года назад +1

      So you want to run a batch at the same time every day on a VM in the cloud…
      The easiest way is inside windows
      Using scheduled tasks.
      The batch file will run according to your schedule every day
      You could also do this from Azure using something like Azure Functions or powershell DSC
      The custom script extension could also be used but it’s function is to run a script now
      So you would have to have another scheduled process to send it the file and tell it to run, so not ideal.

  • @bidemibello9983
    @bidemibello9983 4 года назад +1

    Hello, I have a question with Extension. The goal is to setup expiry date for some user accounts(Contractors, consultants). I was wondering if i can create custom extension to achieve this.

    • @AzureAcademy
      @AzureAcademy  4 года назад +1

      yes you can. The PowerShell would execute on the local VM in a system context unless you declare another context. You can have that code run against another system like a domain controller...assuming you have the right 😊 You can also do this with an Azure Automation account or Azure DevOps so you don't have to pay for a VM that is always running

  • @srinivasanrajendran3380
    @srinivasanrajendran3380 4 года назад +1

    How do i deploy two custom script extension on same VM, for example one script i am installing Domain controller on the VM upon reboot i want to execute one more script that creates domain user accounts. Arm template not allowing multiple custom script extension on one VM :(

    • @AzureAcademy
      @AzureAcademy  4 года назад +1

      The purpose of the custom script extension is to be used as a 1 time operation.
      a VM can only have 1 custom script extension at a time.
      If you want to do more than 1 operation...but cannot put it in the same script, then I suggest PowerShell DSC or another configuration tool.
      The other thing you can do is to install the customer script extension and do your first process...then run another command or template to remove the custom script extension.
      then install the new ectension...see why DSC is better 😊

  • @mosksky
    @mosksky 5 лет назад +1

    Thank you Dean, i think it would be beneficial to also cover t-shooting steps, where to trace the logs
    Logging: C:\WindowsAzure\Logs\Plugins\Microsoft.Compute.CustomScriptExtension
    Script: C:\Packages\Plugins\Microsoft.Compute.CustomScriptExtension\1.*\Downloads\

    • @AzureAcademy
      @AzureAcademy  5 лет назад +1

      Thanks for the feedback, I will see how we can explore this further

  • @uddinsiddiqui
    @uddinsiddiqui 4 года назад +1

    Thank you for the Video. Is it possible to post a video for calling a powershell script on a VM from a Runbook in Azure

    • @AzureAcademy
      @AzureAcademy  4 года назад +3

      sure can...stay tuned

    • @vengateshkaliraj
      @vengateshkaliraj 4 года назад +1

      @@AzureAcademy Thanks! did we posted a video on calling a powershell script on a VM from a Runbook in Azure
      ?

    • @AzureAcademy
      @AzureAcademy  Год назад +1

      they are on my channel

  • @dnyaneshawar1
    @dnyaneshawar1 3 года назад +1

    Can someone help me on below error.
    VM has reported a failure when processing extension 'CustomScriptExtension'. Error message: \"Failed to download all specified files. Exiting. Error Message: The remote server returned an error: (404) Not Found.

    • @AzureAcademy
      @AzureAcademy  3 года назад +1

      sorry to hear you are getting an error...The error shows that the VM failed to download the files. When you gave the file to the extension, where did you store it? Public repo like GitHub, or from your Computer, or an Azure storage account?

    • @dnyaneshawar1
      @dnyaneshawar1 3 года назад +1

      @@AzureAcademy thank you for the reply I am able to run the arm template with extension.

    • @AzureAcademy
      @AzureAcademy  3 года назад +1

      @@dnyaneshawar1 AWESOME!