Deploying to Azure
Hi there,
This script seems to be out of date:
https://github.com/appveyor/ci/blob/master/scripts/enterprise/copy-master-image-azure.ps1
I don't seem to be able to deploy from the unleased VHD from my master VM? Is there a better tutorial?
Chris
Comments are currently closed for this discussion. You can start a new one.
Keyboard shortcuts
Generic
? | Show this help |
---|---|
ESC | Blurs the current field |
Comment Form
r | Focus the comment reply box |
---|---|
^ + ↩ | Submit the comment |
You can use Command ⌘
instead of Control ^
on Mac
1 Posted by Ilya Finkelshte... on Apr 08, 2019 @ 05:02 PM
Hi Chris,
I checked internal traces related to your project. Azure VMs is being created OK, but AppVeyor never "hear back" from it. This maybe connected to the fact that AppVeyor build agent was not started automatically. Please check that you completed all 4 steps from this part of documentation:
When you started your master VM it should auto-logon and agent should be started interactively. When you double-checked that, re-create VHD from the master VM.
Let us know how it goes.
Ilya.
2 Posted by Chris Belfield on Apr 08, 2019 @ 06:38 PM
Hi Ilya,
The current script for creating snapshots from vhd doesn't work, is there
an updated version?
3 Posted by Ilya Finkelshte... on Apr 08, 2019 @ 08:01 PM
According to the screenshots you sent in the initial post, I checked internal logs and pointed you to the probable root cause why build is not starting,
If you believe that there is some problem with
copy-master-image-azure.ps1
, please provide more information: how you execute it, what error are you getting and so on.4 Posted by Chris Belfield on Apr 08, 2019 @ 08:21 PM
The azure functions being called in the script are not up to date with the
latest version of powershell. Can you confirm this?
5 Posted by Ilya Finkelshte... on Apr 08, 2019 @ 08:37 PM
Was not aware of that. Will do repro on clean machine with the latest Azure PowerShell and see. What specific cmdlet or command you see as outdated on your machine? What error do you see?
6 Posted by Chris Belfield on Apr 09, 2019 @ 08:22 AM
I'm using the latest powershell build on ubuntu provided by Microsoft and
the cmdlets don't exist.
7 Posted by Ilya Finkelshte... on Apr 09, 2019 @ 08:58 AM
Did you install Azure Powershell module?
8 Posted by Chris Belfield on Apr 09, 2019 @ 09:11 AM
This what I'm using on Ubuntu
https://docs.microsoft.com/en-us/powershell/module/microsoft.powershell.core/about/about_pwsh?view=powershell-6
https://websiteforstudents.com/install-microsoft-powershell-core-for-linux-on-ubuntu-16-04-18-04/
[image: Screenshot from 2019-04-09 10-03-04.png]
Version: ps from procps-ng 3.3.12
9 Posted by Chris Belfield on Apr 09, 2019 @ 09:27 AM
[image: Screenshot from 2019-04-09 10-25-43.png]
10 Posted by Chris Belfield on Apr 09, 2019 @ 11:36 AM
https://github.com/Azure/azure-powershell/issues/5579
Here is where they talk about AzureRM being deprecated
11 Posted by Chris Belfield on Apr 09, 2019 @ 05:08 PM
Hey Ilya,
So it turns out that AzureRM is only supported on Windows desktop!
Finally got somewhere and started deploying.
I'm noticing my jobs queue up when there is no other jobs running? Is there
a timeout I can adjust?
[image: Screenshot from 2019-04-09 18-06-28.png]
12 Posted by Chris Belfield on Apr 09, 2019 @ 05:09 PM
[image: Screenshot from 2019-04-09 18-08-42.png]
[image: Screenshot from 2019-04-09 18-08-36.png]
13 Posted by Ilya Finkelshte... on Apr 09, 2019 @ 05:44 PM
Starting
is notQueued
.Starting
means you have enough parallel jobs in your plan and jobs are being started, which in this case means Azure VM based on your VHD is being created. It usually takes about 3-4 minutes to provision VM on Azure and being this time inStarted
state is expected.14 Posted by Chris Belfield on Apr 09, 2019 @ 07:07 PM
Yea I'm not seeing the VMs though
15 Posted by Ilya Finkelshte... on Apr 09, 2019 @ 07:09 PM
You mean you do not VMs in Azure Portal? Did build jobs started after
Starting
stage?16 Posted by Chris Belfield on Apr 10, 2019 @ 11:57 AM
Yea Ilya, basically when I start the job it seems to queue up, but does not
deploy to Azure portal. It seems to be waiting for something and I'm
getting no errors from Azure.
I have the timeout set to 300 and for some reason it's timing out? But then
some jobs start?
[image: Screen Shot 2019-04-10 at 12.57.14 pm.png]
17 Posted by Ilya Finkelshte... on Apr 10, 2019 @ 11:50 PM
Here is an error I see in internal traces:
You might have too much builds already started, or a lot of them are in
Starting
state. Also what can happen is that builds just recently ended and AppVeyor immediately started deleting respective VMs, but they are still not deleted from Azure point of view.I would recommend that Azure VMs limit to be at least 50% greater than AppVeyor parallel jobs limit to avoid those edge cases.
18 Posted by Ilya Finkelshte... on Apr 10, 2019 @ 11:53 PM
Sorry, updated: Azure VMs limit to be at least 50% greater than AppVeyor parallel jobs limit.
You can check your account AppVeyor parallel jobs limit in your plan on the Billing page. Also you can set
Max Jobs
at project level (supported in both YAML and UI).Ilya Finkelshteyn closed this discussion on Jun 11, 2019 @ 09:01 PM.