Two gitlab-ci runners for one project - gitlab-ci-runner

I used to have a project on github with a travis and an appveyor integration service configured. Thus I was able to make sur my project was compiling ok on both OSX and Windows plateform.
I'm now working with gitlab and ci runners. I have two runners configured:
One on a OSX machine
One on a Windows machine
Unfortunately when I add both runners in my project settings > CI/CD > Runners settings, only one is triggered upon push (the OSX one).
If I disable the OSX runner, the Windows runner is triggered fine.

One Job is only running by one runner.
I guess you want that your Job is running twice
on your windows runner
on your osx runner
To do so
Tag your runners (e.g. win and mac)
duplicate your job for the same stage and add for your windows runner job the win tag and for your mac runner job the mac tag.
This should take care that both runners will run the job in the next pipeline.
stages:
- build
mac_build:
stage: build
tags:
- mac
script:
- something ...
win_build:
stage: build
tags:
- win
script:
- something ...

Related

How to use packagesbuild with GitHub Actions

One of my Open Source projects uses Packages to build the macOS installer. After GUI-based setup of the pckgproject file, the installer build can be easially invoked from the command line through the packagesbuild command.
I'm now setting up a GitHub Actions based build workflow, running on the GitHub-hosted runners, which should ideally create a ready-to-use installer, so I need to invoke packagesbuild during that process. Unfortunately packagesbuild is not available on the macos-10.15 runner used. I don't see any option to install it during the workflow run, as it's not available through e.g. homebrew but maybe I'm overlooking something. Is there any option I'm overlooking beneath rebuilding my installer and switching to pkgbuild?

How must Teamcity be configured to work withtout SVC?

I am new in Teamcity and I created a Build, with a RunScript step.
I changed nothing in the source control configuration of this step.
The goal of the Build step is to run a script nothing else.
When running the build, Teamcity tries to do a source checkout (not configured) and stays blocked there.
What is the correct Teamcity SVC configuration in order that the build works even when SVC is not configured? Is it even possible or I should configure a fake SVC system like GIT to get it running?
With Teamcity, as with TFS, when you want to handle UI Tests, you should install the Test Agents as Interactive and not as Service.
If you Install them as Services, you will not have access to all the functionalities you need for UI testing.

Git, Node.js and NPM on public server

I have install Git, Node.js and NPM on my machine and have successfully been able to run a progressive web app on Chrome through the LocalHost. Now what about when I want to run this web app on a public server? Will I have to install Git, Node.js and NPM on my web hosting account? Or are these components already installed on web hosting servers in general (like would be an app like cPanel)?
By the way, would you be able to recommend any good FTP application for Mac that can upload zillions of files easily (not 1 by 1)?
You will need Node on the host server, but not NPM or Git (although NPM will be there by default when you install Node).
Typically what you want is to setup a "Continuous Integration / Continuous Delivery" platform. You can use free options like Travis or Jenkins or you can just use a shell script and run it through AWS Lambda or something like that.
Very simplified version:
You push code to Git
CI/CD detects the code check-in (polls) and pulls latest from Git on an Agent
CI/CD runs a "build" on the Agent, which for Node is at least npm install but can include Grunt, Gulp, Webpack, or a host of other useful steps.
CI/CD publishes the result of the build to a target server.
Here you have five machines involved:
Git server
Your local dev box
CI/CD server
CI/CD agent
production server
Hope this helps you get started in the right direction.

How do I choose an artifact from Nexus in a Hudson / Jenkins job?

I have a job in Hudson server A which builds an artifact and deploys it to Nexus. I have another job in a completely separate Hudson server B which needs to download the artifact and deploy it. This job is normally run manually, and the person running it needs to indicate which version of the artifact to deploy - they may not always want to deploy the latest version (e.g. to roll back to a previous known good version).
Currently, I achieve this by using a parameterized build, and require the user to pass in the artifact version number; the job then uses the Execute shell build step to run wget on a URL constructed using the parameter. This is error prone.
Ideally I'd like a plugin that lets the user browse the artifact versions in the Nexus repository and pick and choose the one to deploy, but I'm open to other suggestions. A plugin that also handles the download would be nice, but I can live without it as long as I can still get a string that I can use in shell commands.
I've looked through the available Hudson & Jenkins plugins around Maven style artifact repositories, but they all seem more concerned with pushing artifacts into repos rather than getting them back down.
I'm using Hudson's "Copy Artifact" in other jobs, to get artifacts from other Hudson jobs on the same server, but this doesn't work across different Hudson servers, which is why I've turned to Nexus (which we're already using anyway).
Does anyone have any suggestions?
I recommend using rundeck to execute your deployments.
There is a rundeck plugin for Nexus that enables rundeck to display a pull down menu of available versions in Nexus.
There is a rundeck plugin for Jenkins that can be used to invoke deployments using rundeck and kick-off post deployment jobs (like integration testing) inn Jenkins.

Run a task before svn check-out

I would like to run a task (stop a running vm machine) before Jenkins starts the check-out.
The reason is: VM blocks access to some files I have to update via subversion.
Is this possible?
There are two plugins for controlling virtual machines, depending on whether you are using VirtualBox or VMWare.
I'm quite sure you can configure the pre-build step to be "Suspend" as shown in the images, at least for VMWare.
VMware Plugin
VirtualBox Plugin
Edit your project and set:
Configure M2 Extra Build Steps --> Execute shell --> Type in whatever you'd like to do. For example:
# Wipe the local repository before each build.
rm -rf $WORKSPACE/.repository
Have a look at How do I trigger another job from hudson as a pre-build step?. I think this has been asked before there.