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

NAS-132261 / 25.04 / Setup Truenas Connect integration #11355

Merged
merged 19 commits into from
Jan 20, 2025
Merged

Conversation

gmboknat
Copy link
Collaborator

Changes:
Setup Truenas Connect integration

Testing:

  1. For TNC logo to appear, the user needs to set the config
    midclt call tn_connect.update '{ "enabled": true, "ips": [ {{ NAS_IP }} ], "account_service_base_url": "https://account-service.dev.ixsystems.net/", "leca_service_base_url": "https://leca-server.dev.ixsystems.net/", "tnc_base_url": "https://truenas.connect.dev.ixsystems.net/"}'
  2. Click the icon and then click the settings button
  3. Once the form dialog appears, click the generate token
  4. Click the Connect button, and it opens a new tab for adding the system to TNC
  5. Once the process is done, the NAS will get a ws error that causes the page to reload

Downstream

Affects Reasoning
Documentation

@gmboknat gmboknat requested a review from a team as a code owner January 18, 2025 23:09
@gmboknat gmboknat requested review from denysbutenko and removed request for a team January 18, 2025 23:09
@bugclerk bugclerk changed the title NAS-132261: Setup Truenas Connect integration NAS-132261 / 25.04 / Setup Truenas Connect integration Jan 18, 2025
@bugclerk
Copy link
Contributor

Copy link

codecov bot commented Jan 18, 2025

Codecov Report

Attention: Patch coverage is 81.13208% with 30 lines in your changes missing coverage. Please review.

Project coverage is 82.86%. Comparing base (15f034f) to head (0ac4075).
Report is 3 commits behind head on master.

✅ All tests successful. No failed tests found.

Files with missing lines Patch % Lines
...ruenas-connect/services/truenas-connect.service.ts 39.13% 28 Missing ⚠️
src/app/modules/layout/topbar/topbar.component.ts 75.00% 2 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff            @@
##           master   #11355    +/-   ##
========================================
  Coverage   82.85%   82.86%            
========================================
  Files        1660     1665     +5     
  Lines       59414    59582   +168     
  Branches     6241     6250     +9     
========================================
+ Hits        49226    49370   +144     
- Misses      10188    10212    +24     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

Copy link
Collaborator

@undsoft undsoft left a comment

Choose a reason for hiding this comment

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

Doing:

midclt call tn_connect.update '{ "enabled": true, "ips": [ {{ NAS_IP }} ], "account_service_base_url": "https://account-service.dev.ixsystems.net/", "leca_service_base_url": "https://leca-server.dev.ixsystems.net/", "tnc_base_url": "https://truenas.connect.dev.ixsystems.net/"}'

results in
[EINVAL] tn_connect_update: Input should be a valid dictionary or instance of TNCUpdateArgs for me.

@gmboknat
Copy link
Collaborator Author

gmboknat commented Jan 19, 2025

@undsoft make sure to provide ip address
midclt call tn_connect.update '{ "enabled": true, "ips": ["10.220.36.85"], "account_service_base_url": "https://account-service.dev.ixsystems.net/", "leca_service_base_url": "https://leca-server.dev.ixsystems.net/", "tnc_base_url": "https://truenas.connect.dev.ixsystems.net/"}'

@gmboknat gmboknat requested a review from undsoft January 20, 2025 00:16
Copy link
Collaborator

@undsoft undsoft left a comment

Choose a reason for hiding this comment

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

I had some issues where connection status only updated after I reloaded the page, but other than that it worked okay. I'm going to merge what we currently have and we can test some more later.

@undsoft undsoft merged commit 8883779 into master Jan 20, 2025
11 checks passed
@undsoft undsoft deleted the NAS-132261 branch January 20, 2025 20:43
@bugclerk
Copy link
Contributor

This PR has been merged and conversations have been locked.
If you would like to discuss more about this issue please use our forums or raise a Jira ticket.

@truenas truenas locked as resolved and limited conversation to collaborators Jan 20, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants