Self-hosted setup, I'm struggling with a couple of concepts, help would be appreciated

Oliver Collyer's Avatar

Oliver Collyer

25 Feb, 2020 08:00 PM

So I've managed to set up AppVeyer self-hosting on a Windows 10 machine, and linked it to Gitea running on a Synology NAS.

I've then followed these instructions to utilise a Windows PC as a build agent:

https://www.appveyor.com/docs/byoc/windows/

This has created a cloud with the name of that Windows PC and I can reference the image "Windows" in my YAML file and it produce Windows builds. So far so good.

What I do not really understand is what I need to do to add a macOS machine to the cloud. Do I follow the wizard to produce another separate cloud for the macOS machine? Or am I meant to somehow link the macOS machine to the cloud I created for Windows? If it's a different cloud, then how do I tell my YAML that macOS builds should go to the macOS cloud, and Windows to the Windows cloud? Or is it enough to just specify the images and then it all works it out itself? If this is the case, what is the "build_cloud" YAML entry intended to do?

Essentially what I am trying to achieve is a self-hosted setup consisting of four devices...

Synology NAS running Gitea for the Git server
Windows 10 PC running AppVeyor server
Windows 10 PC for doing Windows builds
macOS computer for doing macOS, iOS, tvOS and Android builds.

...and I'm not clear on how I am meant to set this up.

  1. Support Staff 1 Posted by Feodor Fitsner on 25 Feb, 2020 11:33 PM

    Feodor Fitsner's Avatar

    Hi Oliver,

    Thanks for trying out AppVeyor Server!

    For connecting macOS computer to the existing AppVeyor installation you should, basically, add a new "cloud" in the AppVeyor and then install Host Agent. Look at this guide: https://www.appveyor.com/docs/byoc/mac/#manual-setup

    Regarding pointing builds to either Windows or macOS machine - you can specify both image and build_cloud attributes, or if you edit image details and specify image "preferable" build cloud then you can specify image only in your appveyor.yml.

  2. 2 Posted by Oliver Collyer on 26 Feb, 2020 05:56 AM

    Oliver Collyer's Avatar

    Thank you for that.

    So currently I do the following to specify the build script etc for a Windows build:

    >>>>>

    version: 1.0.{build}
    build_cloud: Windows-PC
    image:
    - Windows
    - macOS

    for:
    -
      matrix:
        only:
          - image: Windows

      build_script:

    <<<<<

    So are you saying I would add the build_cloud clause to the matrix only too, to support macOS builds:

    >>>>>

    version: 1.0.{build}
    build_cloud:
    - Windows-PC
    - Mac-Computer

    image:
    - Windows
    - macOS

    for:
    -
      matrix:
        only:
          - image: Windows
          - build_cloud: Windows-PC

      build_script:
          ...windows build script goes here

    -
      matrix:
        only:
          - image: macOS
          - build_cloud: Mac-Computer

      build_script:
          ...macOS build script goes here

    <<<<<

    Like that?

  3. Support Staff 3 Posted by Feodor Fitsner on 26 Feb, 2020 06:01 AM

    Feodor Fitsner's Avatar

    Go to Windows image settings and specify Windows-PC as build cloud, then go to macOS image settings and specify Mac-Computer as build cloud, so the matrix could be simplified to just images: https://www.appveyor.com/docs/build-configuration/#specializing-mat...

  4. 4 Posted by Oliver Collyer on 26 Feb, 2020 07:09 AM

    Oliver Collyer's Avatar

    Got it thank you very much for your prompt support, this gives me great confidence that your platform is something I can use for my projects.

  5. Support Staff 5 Posted by Feodor Fitsner on 26 Feb, 2020 06:22 PM

    Feodor Fitsner's Avatar

    Sounds great!

Reply to this discussion

Internal reply

Formatting help / Preview (switch to plain text) No formatting (switch to Markdown)

Attaching KB article:

»

Attached Files

You can attach files up to 10MB

If you don't have an account yet, we need to confirm you're human and not a machine trying to post spam.

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