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

Container Instances - Use of Private IPS #90

Merged
merged 20 commits into from
Jan 7, 2022

Conversation

sparsick
Copy link
Contributor

@sparsick sparsick commented Dec 15, 2021

  • Make sure you are opening from a topic/feature/bugfix branch (right side) and not your main branch!
  • Ensure that the pull request title represents the desired changelog entry
  • Please describe what you did
  • Link to relevant issues in GitHub or Jira
  • Link to relevant pull requests, esp. upstream and downstream changes
  • Ensure you have provided tests - that demonstrates feature works or fixes the issue

Based on @jplorier PR #60 I fixed the checkstyle issues and compilation errors.

Fixed #55
Fixes #25
Fixes #60

Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

Appears to be missing setting the variable?

I would expect an update in AciService, see

@sparsick sparsick marked this pull request as draft December 16, 2021 10:18
@sparsick
Copy link
Contributor Author

Thanks @timja for reviewing it. I will recheck the AciService. Thanks for your hint.

@sparsick sparsick marked this pull request as ready for review December 16, 2021 11:04
@sparsick sparsick requested a review from timja December 16, 2021 11:05
Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

Couple of minor comments can you confirm you've tested this and it's working for you?

@sparsick
Copy link
Contributor Author

@timja thank you for your review. I found that the config was not saved correctly (I fixed it), so my previous tests are invalid. Now I found out that the container needs a network profile. So I have to investigate the azure documentation how to do it in the best way. I think I will have to do more changes, therefore, I put this PR in draft again.

@sparsick
Copy link
Contributor Author

I replaced the checkbox by an optional block with two textboxes for the needed virtual network information.

grafik

Still in progress because I have to adjust the deploy template.

@sparsick sparsick marked this pull request as ready for review January 4, 2022 13:08
@sparsick sparsick requested a review from timja January 4, 2022 13:10
@sparsick
Copy link
Contributor Author

sparsick commented Jan 4, 2022

I tested the changes manually for both cases (public ip address and private ip address). A known limitation is that vnet and subnet must be in the resource group that is defined in the above field Azure Container Instance -> Resource Group

Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

It would be nice to see a Configuration as code test showing that it works there.

This is looking really close, the blockers are in the src/main/resources/com/microsoft/jenkins/containeragents/aci/AciContainerTemplate/config.jelly file.

I haven't tested this myself interactively, have you? I see you posted after I started my review 👍

Juan Pablo Lorier and others added 12 commits January 5, 2022 18:39
#55: Update src/main/resources/com/microsoft/jenkins/containeragents/aci/AciContainerTemplate/config.jelly
#55: Update src/main/resources/com/microsoft/jenkins/containeragents/aci/AciContainerTemplate/config.jelly

Co-authored-by: Tim Jacomb <21194782+timja@users.noreply.github.com>
Co-authored-by: Tim Jacomb <21194782+timja@users.noreply.github.com>
@sparsick
Copy link
Contributor Author

sparsick commented Jan 5, 2022

It would be nice to see a Configuration as code test showing that it works there.

I started with a JCasC test, but I fell in a rabbit hole because this plugin needs a dependency update. If it is OK for you, I will hand it later after a dependency update.

@sparsick sparsick requested a review from timja January 5, 2022 19:34
@timja
Copy link
Member

timja commented Jan 5, 2022

I have a dependency update ready to go locally just need one component released, should have it up tonight / tomorrow morning UTC

@timja
Copy link
Member

timja commented Jan 5, 2022

PR is #92, I've tested it locally and the tests pass, bom should be being released atm

Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

much better, infinite loop is the main blocker but the rest should be really quick

Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

non blocking comments

@sparsick sparsick marked this pull request as draft January 7, 2022 10:25
@sparsick sparsick marked this pull request as ready for review January 7, 2022 11:23
@sparsick sparsick requested a review from timja January 7, 2022 11:23
@sparsick
Copy link
Contributor Author

sparsick commented Jan 7, 2022

I added a minimal JCasC test for my feature. I hope that is enough for the first. Furthermore, I will open new issues for the non-blocking stuff.

Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

final nits, the configuration as code plugin is in the plugin bom so you don't need to specify a version https://github.com/jenkinsci/bom

pom.xml Outdated Show resolved Hide resolved
pom.xml Outdated Show resolved Hide resolved
pom.xml Outdated Show resolved Hide resolved
@sparsick sparsick requested a review from timja January 7, 2022 11:59
Copy link
Member

@timja timja left a comment

Choose a reason for hiding this comment

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

Just to confirm you've re-tested this with the changes made during review?

I checked the UI saving etc but haven't run an actual test, all looks good though

@timja timja merged commit 052b1a7 into jenkinsci:master Jan 7, 2022
sparsick added a commit to sparsick/azure-container-agents-plugin that referenced this pull request Jan 7, 2022
@sparsick
Copy link
Contributor Author

sparsick commented Jan 7, 2022

I retested it. I found that Instance Identity does not work as expected.

grafik

I rollbacked it to legacyIdentifierId this works.

oh sorry. I was too late with my answer. I will open a new PR.

@sparsick
Copy link
Contributor Author

sparsick commented Jan 7, 2022

@timja New PR #95

@timja
Copy link
Member

timja commented Jan 7, 2022

np I cancelled the release

@sparsick
Copy link
Contributor Author

sparsick commented Jan 7, 2022

np I cancelled the release

Thank you 🙏

@timja
Copy link
Member

timja commented Jan 7, 2022

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Container Instances - Use of Private IPS Azure contains Agents - Private IP Address
2 participants