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

feat: create reverse proxy for logo when plugin created #2652

Merged
merged 2 commits into from
Nov 3, 2022

Conversation

guqing
Copy link
Member

@guqing guqing commented Nov 2, 2022

What type of PR is this?

/kind improvement
/area core
/milestone 2.0

What this PR does / why we need it:

插件 logo 支持配置外部 URL 或相对于 resources 的路径

Console 端展示插件 logo 时使用的字段需要使用 status.logo 而非 spec.logo

Which issue(s) this PR fixes:

Fixes #2651

Special notes for your reviewer:

how to test it?

  1. 插件配置 logo 为外部 url 例如 https://guqing.xyz/avatar
  2. 安装此插件后不会注册 ReverseProxy 规则
  3. logo 配置为相对于 resources 的路径例如:/logo.png
  4. 安装此插件后可以访问到 /plugins/{your-plugin-name}/assets/logo.png
  5. 开发模式启动插件后,修改了 plugin.yaml 中的 spec.logo 则也会更新 ReverseProxy 的 rule

/cc @halo-dev/sig-halo

Does this PR introduce a user-facing change?

插件 Logo 支持配置外部 URL 或相对于 resources 的路径

@f2c-ci-robot f2c-ci-robot bot added kind/improvement Categorizes issue or PR as related to a improvement. release-note Denotes a PR that will be considered when it comes time to generate release notes. labels Nov 2, 2022
@f2c-ci-robot f2c-ci-robot bot added this to the 2.0 milestone Nov 2, 2022
@f2c-ci-robot f2c-ci-robot bot added the area/core Issues or PRs related to the Halo Core label Nov 2, 2022
Copy link
Member

@ruibaby ruibaby left a comment

Choose a reason for hiding this comment

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

/lgtm

Console 的适配 halo-dev/console#678

@f2c-ci-robot f2c-ci-robot bot added the lgtm Indicates that a PR is ready to be merged. label Nov 2, 2022
Copy link
Member

@JohnNiang JohnNiang left a comment

Choose a reason for hiding this comment

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

/approve

@f2c-ci-robot
Copy link

f2c-ci-robot bot commented Nov 3, 2022

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: JohnNiang

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@f2c-ci-robot f2c-ci-robot bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Nov 3, 2022
@f2c-ci-robot f2c-ci-robot bot merged commit 73df5e4 into halo-dev:main Nov 3, 2022
f2c-ci-robot bot pushed a commit to halo-dev/console that referenced this pull request Nov 3, 2022
#### What type of PR is this?

/kind improvement
/milestone 2.0

#### What this PR does / why we need it:

修改插件 Logo 的使用字段为 `status.logo`。用于适配 halo-dev/halo#2652

#### Which issue(s) this PR fixes:

Fixes halo-dev/halo#2651

#### Screenshots:

<img width="1663" alt="image" src="https://user-images.githubusercontent.com/21301288/199447142-0c90b200-3976-498e-88e1-dd3c5377ab73.png">

#### Special notes for your reviewer:

/cc @halo-dev/sig-halo-console 

测试方式:

1. Halo 需要切换到 halo-dev/halo#2652 分支。
2. 检查插件列表的 Logo 是否显示正常。

#### Does this PR introduce a user-facing change?

```release-note
None
```
JohnNiang pushed a commit to JohnNiang/halo that referenced this pull request Mar 2, 2023
#### What type of PR is this?

/kind improvement
/milestone 2.0

#### What this PR does / why we need it:

修改插件 Logo 的使用字段为 `status.logo`。用于适配 halo-dev#2652

#### Which issue(s) this PR fixes:

Fixes halo-dev#2651

#### Screenshots:

<img width="1663" alt="image" src="https://user-images.githubusercontent.com/21301288/199447142-0c90b200-3976-498e-88e1-dd3c5377ab73.png">

#### Special notes for your reviewer:

/cc @halo-dev/sig-halo-console 

测试方式:

1. Halo 需要切换到 halo-dev#2652 分支。
2. 检查插件列表的 Logo 是否显示正常。

#### Does this PR introduce a user-facing change?

```release-note
None
```
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. area/core Issues or PRs related to the Halo Core kind/improvement Categorizes issue or PR as related to a improvement. lgtm Indicates that a PR is ready to be merged. release-note Denotes a PR that will be considered when it comes time to generate release notes.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

插件允许在未启动时访问到 logo
3 participants