Skip to content
Snippets Groups Projects

Add runner registration instructions (2)

Merged Miguel Rincon requested to merge 383139-add-runner-registration-instructions into master

What does this MR do and why?

This change adds specific registration instructions for each platform according to the user's selection during runner creation.

This is a large MR!

This MR includes over 700 lines :scream: however it is only new static page, so it's UX is quick to review, you'll see the entire change in a single place. I'll leave some extra comments so reviewing is easier :bow:

This is a summary of the changes:

  • We are working behind the create_runner_workflow feature flag.
  • Adds a new mounting point for our page at #js-admin-register-runner (a bit of boilerplate)
  • Adds a new app component with an Apollo query in it (so a bit more bolierplate)
  • Renders instructions for different platforms, with a helper cli_command component

Related MRs

Add CreateRunner Mutation Endpoint (!110593 - merged)
Call API to create runner (1) (!111789 - merged)
Add runner registration instructions (2) (!112487 - merged) :point_left: you are here
Add installation command for drawer (3) (!112561 - merged)

Screenshots or screen recordings

image
2023-02-23_13.04.50

UI notes

After a discussion over Slack at https://gitlab.slack.com/archives/C0199KBMY59/p1676910832818489 (internal) I used user-select: none; in part of the command to allow the user to have their command in a single line, so it behaves like the copy button:

This allows us to avoid using line breaks in the command.

The command prompt (e.g. $) is also ignored when copying.

How to set up and validate locally

  1. Enable the feature flag: in your console rails c, and then Feature.enable(:create_runner_workflow)
  2. Visit Admin -> CI/CD -> Runners
  3. Select the "New instance runner" button
  4. Input values to create a new runner, select a platform you want.
  5. After "submit", confirm the success message
  6. In the runner list a "Never connected" runner will appear.

MR acceptance checklist

This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #383139 (closed)

Edited by Ali Ndlovu

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Miguel Rincon deleted the 383139-add-runner-creation-button branch. This merge request now targets the master branch

    deleted the 383139-add-runner-creation-button branch. This merge request now targets the master branch

  • Miguel Rincon added 462 commits

    added 462 commits

    Compare with previous version

  • Miguel Rincon marked this merge request as ready

    marked this merge request as ready

  • Bundle size analysis [beta]

    This compares changes in bundle size for entry points between the commits 5ce7bc9a and c854587d

    :sparkles: Special assets

    Entrypoint / Name Size before Size after Diff Diff in percent
    average 3.49 MB 3.5 MB +1.61 KB 0.0 %
    mainChunk 2 MB 2 MB - 0.0 %

    :fearful: Significant Growth: 1

    Expand
    Entrypoint / Name Size before Size after Diff Diff in percent
    pages.admin.runners.register 13.14 KB 731.09 KB +717.96 KB 5464.4 %

    Your MR has at least one entrypoint growing significantly (more > 1 KB or 2%). If you write new or extend existing features, this is expected and there is nothing to worry about.

    Please consider pinging someone from the FE Foundations (@leipert, @markrian, @ohoral or @pgascouvaillancourt) for review, if you are unsure about the size increase.

    Note: We do not have exact data for 5ce7bc9a. So we have used data from: 074fced0.
    The intended commit has no webpack pipeline, so we chose the last commit with one before it.

    Please look at the full report for more details


    Read more about how this report works.

    Generated by :no_entry_sign: Danger

  • Miguel Rincon added 1 commit

    added 1 commit

    • 7d5cc78d - Add runner registration instructions

    Compare with previous version

  • Miguel Rincon changed the description

    changed the description

  • Miguel Rincon added 1 commit

    added 1 commit

    • d52f3641 - Add runner registration instructions

    Compare with previous version

  • Miguel Rincon added 1 commit

    added 1 commit

    • b1c378de - Add runner registration instructions

    Compare with previous version

  • Miguel Rincon added 1 commit

    added 1 commit

    • 672aa364 - Add runner registration instructions

    Compare with previous version

  • Miguel Rincon changed the description

    changed the description

  • Miguel Rincon
  • Miguel Rincon
  • Miguel Rincon
  • Miguel Rincon
  • Miguel Rincon
  • Miguel Rincon requested review from @robyrne

    requested review from @robyrne

  • Miguel Rincon changed the description

    changed the description

  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Loading
  • Please register or sign in to reply
    Loading