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

Resurrect CI #2607

Closed
dsyme opened this issue Sep 27, 2021 · 2 comments
Closed

Resurrect CI #2607

dsyme opened this issue Sep 27, 2021 · 2 comments

Comments

@dsyme
Copy link
Collaborator

dsyme commented Sep 27, 2021

@sergey-tihon @yazeedobaid It looks like we need to resurrect CI

First, we should move from Azure Dev Ops to in-repo GitHub Actions.. The Azure DevOps azure-pipelines.yml from AzureDevOps is below. More will be needed

@matthid If you can give us any assistance that would be great.

steps:
- checkout: self
  clean: true
  lfs: true
- task: DotNetCoreInstaller@0
  displayName: 'Use .NET Core sdk 2.1.402'
  inputs:
    version: 2.1.402
# Paket - Setup CredMgr
- task: matthid.paket-private.c2aea098-6aab-4cd3-9a0c-57b074df3df5.setCredentialManager@0
  displayName: 'Setup Paket Credential Manager'
- bash: ./.paket/paket.exe update -v # contents of the script to run
  displayName: Paket update  # friendly name displayed in the UI
  workingDirectory: paket_cred  # initial working directory for the step
  #name: string  # identifier for this step (no spaces allowed)
  #failOnStderr: boolean  # if the script writes to stderr, should that be treated as the step failing?
  #condition: string
  #continueOnError: boolean  # 'true' if future steps should run even if this step fails; defaults to 'false'
  #enabled: boolean  # whether or not to run this step; defaults to 'true'
  #timeoutInMinutes: number
  #env: { string: string }  # list of environment variables to add
# Paket - Cleanup CredMgr
- task: matthid.paket-private.1c4d173c-798c-4636-a842-2da42eb2c20e.paketCredentialCleanup@0
  displayName: 'Cleanup Paket credential manager'
- bash: git clean -xdf .
  displayName: "Git Cleanup"
- bash: |
    if ./.paket/paket.exe update ; then
      echo "Expected paket to fail now."
      exit 1337 # contents of the script to run
    else
      echo "Ok paket failed as expected."
      exit 0
    fi
  displayName: Make sure paket update fails  # friendly name displayed in the UI
  workingDirectory: paket_cred  # initial working directory for the step
  failOnStderr: false
  
# Fake 5 runner
- task: matthid.fake-build-private.dd88f622-7838-44dc-96d6-2372af78775b.FAKE5@1
  displayName: 'Execute build.fsx (no args)'
# Fake 5 runner
- task: matthid.fake-build-private.dd88f622-7838-44dc-96d6-2372af78775b.FAKE5@1
  displayName: 'Execute scripts/build.fsx (without working dir)'
  inputs:
    FakeVersion: '5.6.1'
    FakeScript: 'scripts/build.fsx'
# Fake 5 runner
- task: matthid.fake-build-private.dd88f622-7838-44dc-96d6-2372af78775b.FAKE5@1
  displayName: 'Execute scripts/build.fsx (without working dir + args)'
  inputs:
    FakeVersion: '5.6.1'
    FakeScript: 'scripts/build.fsx'
    ScriptArguments: '-t AssumeScriptsBuild'
# Fake 5 runner
- task: matthid.fake-build-private.dd88f622-7838-44dc-96d6-2372af78775b.FAKE5@1
  displayName: 'Execute scripts/build.fsx (with . working dir)'
  inputs:
    FakeVersion: '5.6.1'
    FakeScript: 'scripts/build.fsx'
    WorkingDirectory: '.'
    ScriptArguments: '-t AssumeScriptsBuild'
# Paths are relative to project root by default
- task: matthid.fake-build-private.dd88f622-7838-44dc-96d6-2372af78775b.FAKE5@1
  displayName: 'Execute build.fsx (with scripts working dir)'
  inputs:
    FakeVersion: '5.6.1'
    FakeScript: 'build.fsx'
    WorkingDirectory: 'scripts'
    ScriptArguments: '-t AssumeRootBuild'
# Paths are relative to project root by default
- task: matthid.fake-build-private.dd88f622-7838-44dc-96d6-2372af78775b.FAKE5@1
  displayName: 'Execute scripts/build.fsx (with scripts working dir + full Command Line)'
  inputs:
    FakeVersion: '5.6.1'
    FakeScript: 'does not matter.fsx'
    WorkingDirectory: 'scripts'
    ScriptArguments: '-t does not matter'
    #PreventSecrets: true
    FakeArguments: 'run build.fsx -t AssumeScriptsBuild'
    #FailOnStdError: true
# Fake 5 runner
- task: matthid.fake-build-private.dd88f622-7838-44dc-96d6-2372af78775b.FAKE5@1
  displayName: 'Execute script/build.fsx (full args + no working dir)'
  inputs:
    FakeArguments: 'run scripts/build.fsx -t AssumeScriptsBuild'
# Fake 5 runner
- task: matthid.fake-build-private.dd88f622-7838-44dc-96d6-2372af78775b.FAKE5@1
  displayName: 'Execute script/build.fsx (full args + with working dir)'
  inputs:
    WorkingDirectory: 'scripts'
    FakeArguments: 'run build.fsx -t AssumeScriptsBuild'

@matthid
Copy link
Member

matthid commented Sep 27, 2021

Any particular reason why you want to move? Adding GitHub Actions is great but the current release process should be fine on Azure DevOps? (Of course any future maintainer is free to use whatever she wants, just out of curiosity).

The release process is basically bootstrapped by fake, so it just a matter of running fake with the correct arguments/environment variables. The only special thing is that the build deploys an artifact and then we bootstrap/use that artifact in the release process/later stages. Other that that (which could be simplified if one wants to) there is not anything special there as far as I can tell. It should be quite straightforward to move to a different system.
Besides:

  • the technical challenges of managing the secrets of the release process when a FAKE integration is not available
  • Managing the build and release stages as this depends on the platform (how to upload an artifact and use that later)

I hope that helps

@dsyme
Copy link
Collaborator Author

dsyme commented Sep 27, 2021

@matthid It's just that the need to know both GitHub and Azure DevOps seems unnecessary, I find Azure DevOps confusing and hard to navigate and the combination really difficult.

To be honest I don't really understand everything and I just want things simplified to the point that someone can come in as a new maintainer and make progress without needing to know much.

We also need to have strong confidence in the release process and understand the exact credentials at every step.

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

No branches or pull requests

2 participants