From 2469226203c654eaeeebdfd98770e340680d620d Mon Sep 17 00:00:00 2001 From: Xstar97TheNoob <9399967+xstar97@users.noreply.github.com> Date: Thu, 20 Jul 2023 03:24:32 -0400 Subject: [PATCH] fix(flaresolverr) disable portal, make service configurable, add gui options. (#10614) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit **Description** Disabled portal make the service configurable and added gui options to manage the app. ⚒️ Fixes # **⚙️ Type of change** - [ ] ⚙️ Feature/App addition - [X] 🪛 Bugfix - [ ] ⚠️ Breaking change (fix or feature that would cause existing functionality to not work as expected) - [X] 🔃 Refactor of current code **🧪 How Has This Been Tested?** **📃 Notes:** **✔️ Checklist:** - [X] ⚖️ My code follows the style guidelines of this project - [X] 👀 I have performed a self-review of my own code - [ ] #️⃣ I have commented my code, particularly in hard-to-understand areas - [ ] 📄 I have made corresponding changes to the documentation - [ ] ⚠️ My changes generate no new warnings - [ ] 🧪 I have added tests to this description that prove my fix is effective or that my feature works - [X] ⬆️ I increased versions for any altered app according to semantic versioning **➕ App addition** If this PR is an app addition please make sure you have done the following. - [ ] 🪞 I have opened a PR on [truecharts/containers](https://github.com/truecharts/containers) adding the container to TrueCharts mirror repo. - [ ] 🖼️ I have added an icon in the Chart's root directory called `icon.png` --- _Please don't blindly check all the boxes. Read them and only check those that apply. Those checkboxes are there for the reviewer to see what is this all about and the status of this PR with a quick glance._ --- charts/stable/flaresolverr/Chart.yaml | 4 +- charts/stable/flaresolverr/questions.yaml | 48 +++++++++++++++++++++-- charts/stable/flaresolverr/values.yaml | 19 ++++++++- 3 files changed, 64 insertions(+), 7 deletions(-) diff --git a/charts/stable/flaresolverr/Chart.yaml b/charts/stable/flaresolverr/Chart.yaml index d67a123d405..b0f7d7a6337 100644 --- a/charts/stable/flaresolverr/Chart.yaml +++ b/charts/stable/flaresolverr/Chart.yaml @@ -9,7 +9,7 @@ home: https://truecharts.org/charts/stable/flaresolverr icon: https://truecharts.org/img/hotlink-ok/chart-icons/flaresolverr.png keywords: - flaresolverr - - jackett + - proxy kubeVersion: ">=1.16.0-0" maintainers: - email: info@truecharts.org @@ -19,7 +19,7 @@ name: flaresolverr sources: - https://github.com/truecharts/charts/tree/master/charts/stable/flaresolverr - https://github.com/FlareSolverr/FlareSolverr -version: 9.0.26 +version: 9.0.27 annotations: truecharts.org/catagories: | - media diff --git a/charts/stable/flaresolverr/questions.yaml b/charts/stable/flaresolverr/questions.yaml index 35261ed62d3..5fe4391582d 100644 --- a/charts/stable/flaresolverr/questions.yaml +++ b/charts/stable/flaresolverr/questions.yaml @@ -1,7 +1,5 @@ # Include{groups} -portals: - open: -# Include{portalLink} +portals: {} questions: # Include{global} # Include{workload} @@ -11,6 +9,50 @@ questions: # Include{podSpec} # Include{containerMain} + - variable: env + label: Image Environment + schema: + additional_attrs: true + type: dict + attrs: + - variable: TEST_URL + label: Test Url + description: Makes a request on start to make sure the web browser is working. + schema: + type: string + required: true + default: "https://www.google.com" + - variable: LOG_LEVEL + label: Log Level + schema: + type: string + required: true + default: info + enum: + - value: info + description: Info + - value: debug + description: Debug + - variable: LOG_HTML + label: Log HTML + description: If true all HTML that passes through the proxy will be logged to the console in debug level. + schema: + type: boolean + required: false + - variable: BROWSER_TIMEOUT + label: Browser Timeout + description: If you are experiencing errors/timeouts because your system is slow, you can try to increase this value. + schema: + type: int + required: true + default: 40000 + - variable: HEADLESS + label: Headless + description: To run the web browser in headless mode or visible. + schema: + type: boolean + required: true + # Include{containerBasic} # Include{containerAdvanced} # Include{containerConfig} diff --git a/charts/stable/flaresolverr/values.yaml b/charts/stable/flaresolverr/values.yaml index 5c5f83444fe..18e6d8aa951 100644 --- a/charts/stable/flaresolverr/values.yaml +++ b/charts/stable/flaresolverr/values.yaml @@ -15,7 +15,22 @@ service: ports: main: port: 8191 - targetPort: 8191 + +workload: + main: + podSpec: + containers: + main: + env: + PORT: "{{ .Values.service.main.ports.main.port }}" + HOST: "0.0.0.0" + TEST_URL: "https://www.google.com" + BROWSER_TIMEOUT: 40000 + HEADLESS: true + LOG_LEVEL: info + LOG_HTML: false + # At this time none of the captcha solvers work, defaults to none. + CAPTCHA_SOLVER: none persistence: config: @@ -24,4 +39,4 @@ persistence: portal: open: - enabled: true + enabled: false