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

Simplify CircleCI config further #19

Merged
merged 6 commits into from
May 2, 2020
Merged

Conversation

seriema
Copy link
Owner

@seriema seriema commented May 1, 2020

Motivation

This is a continuation of PR #18 to make it easier to:

  1. Run the same steps locally
  2. Change CI provider

And also:

  • Identify resource groups in Azure with the build number
  • Prepare for persistent Azure environments, that are created from the master branch and would allow me to use Retro-Cloud as a user that's always on the latest version

This came from experimenting with Travis and needing to differentiate between the resource groups as both CI's were using time stamps. It's also a feature I've wanted for a while because I imagine users wanting a simper resource group, yet needing a unique Azure Storage URL.

Summary

  • Test both RPi and VM from one script running on the RPi
  • Print the RPi's and VM's: .bashrc, .retro-cloud.dev (env vars), and directory listings. Also prints the Azure File Share listing.
    • Note: The Azure script is getting outdated:
     WARNING: Breaking changes in the cmdlet 'Get-AzStorageFile' :
     WARNING:  - "The output type 'Microsoft.Azure.Storage.File.CloudFile' is changing"
     WARNING: 	Change description : The output type will change from CloudFile to AzureStorageFile, and AzureStorageFile will have CloudFile as a child property.
     WARNING: NOTE : Go to https://aka.ms/azps-changewarnings for steps to suppress this breaking change warning, and other information on breaking changes in Azure PowerShell.
    
  • Take an optional parameter when running download-and-run.sh, setup.sh, and teardown.sh. It replaces the default timestamp that's used for resources in Azure.
    • CircleCI resource groups now use "CircleCI-$CIRCLE_BUILD_NUM", e.g. "CircleCI-1721__retro-cloud".

This PR is just for convenience in the future to see what had to change in the scripts to support the merged feature.

seriema added 6 commits May 1, 2020 18:53
Taken from CI and mainly intended for it. It lists several directories and
file contents that are useful to look at when something has gone wrong
during setup or test.
Useful in CI but also for manual testing on the RPi.
I will evaluate the output. CircleCI has easily readible YAML and output,
but TravisCI does not. I might be moving over to TravisCI because they
support privilegied containers.
This will allow persistent environments between CI builds as the
resource group name becomes predictable.

Also output what resoure group is being deleted in teardown.
Makes it easier to find which build is tied to which rg. Also enables
the possibility to have persistent resources, for example from the
master branch.
The output is still valuable even if one or multpile prints fail.
@seriema seriema merged commit 07b98f4 into develop May 2, 2020
@seriema seriema deleted the ci--extract-more-scripts branch May 2, 2020 15:50
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant