Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Azure Pipelines CI support #1571

Merged
merged 4 commits into from
Jul 16, 2019
Merged

Add Azure Pipelines CI support #1571

merged 4 commits into from
Jul 16, 2019

Conversation

smurawski
Copy link
Contributor

Adds a azure-pipelines.yml and tweaks some of the test helpers to get tests running on the hosted build agents.

Sets up builds across Windows, Mac, and Linux and replicates the tests that are happening in Travis and AppVeyor.

Once the PR is merged, we can wire it up to Azure DevOps (along side the other CI environments) to compare behaviors/times.

Copy link

@stuartpreston stuartpreston left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just some minor comments maybe to consider for future builds, but not stopping this getting merged.

MACHINE_USER: kitchen
MACHINE_PASS: K1tch3nY@ml!
MACHINE_PORT: 22
KITCHEN_YAML: ../../../../../../../kitchen.proxy.yml

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a more descriptive way of describing this path? (presume the root of the repo - so $(Build.SourcesDirectory) ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll try that - I tried an absolute path before, but I don't think kitchen liked it.

# Install squid and git.
sudo apt-get update
sudo apt-get -y install squid3 git curl
git clone https://github.com/smurawski/proxy_tests.git

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this a permanent location?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I had to make some updates to that repo given how the package installs on the build agent. I'd be happy to push the changes back upstream, but I'm not sure what else depends on it.

git clone https://github.com/smurawski/proxy_tests.git

# Add the ruby path to the secure path, so we can run the tests elevated (to manage the squid service)
sudo echo 'Defaults secure_path="/opt/hostedtoolcache/Ruby/2.5.5/x64/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/snap/bin"' | sudo tee /etc/sudoers.d/kitchen

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there any way of making this so that when Ruby 2.5.5 disappears from the hosted agent it won't break this script? Can $(Agent.ToolsDirectory) help, can the Use Ruby Version task set the secure path instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stuartpreston I'm following up with the Azure Pipelines team on that very thing. :)

@stuartpreston stuartpreston merged commit edf1d25 into test-kitchen:master Jul 16, 2019
@smurawski smurawski deleted the smurawski/azure-pipelines branch July 16, 2019 19:16
@lock
Copy link

lock bot commented Sep 14, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

@lock lock bot locked as resolved and limited conversation to collaborators Sep 14, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants