Commit Graph

6537 Commits

Author SHA1 Message Date
Thomas Eizinger
6c93ce76bf chore(phoenix-channel): log all errors when connection fails (#8089)
Currently, we are only logging the last error when we fail to connect to
any of the addresses from the portal. This is often not useful because
the last one is likely to be an IPv6 address which may not be supported
on the system so all we learn is "The requested address is not valid in
its context.".
2025-02-11 05:58:32 +00:00
Thomas Eizinger
7dcda1dc74 fix(windows): silence 0x800706D9 when DNS deactivation fails (#8085)
The error code we see here means "There are no more endpoints available
from the endpoint mapper." This has something to do with Windows'
internal RPC communication between components. DNS deactivation is on a
best-effort basis and it appears that everything else is working just
fine, despite this error.

It appears to happen when we shut down our own service, so perhaps it is
just a race condition.
2025-02-11 05:38:37 +00:00
Jamil
063dc73d01 refactor(apple): Remove useless Task.detached (#8063)
Whether we execute a task on the main thread or a background thread
doesn't affect whether the thread is "hung" as reported by Sentry.

Instead, our options for fixing these are:

- Try to use an async version of the underlying API (the [async
version](https://developer.apple.com/documentation/appkit/nsworkspace/open(_:configuration:completionhandler:))
of `open` for example)
- If there is none, and the call could potentially block (most likely to
do disk IO contention), at least schedule this on a new thread using
`Task.detached` but with `.background` priority so that it will avoid
blocking any other execution.

The main takeaway here is that unfortunately, under some conditions,
Sentry will _always_ report an "App Hanging" alert since it's constantly
monitoring all threads for paused execution longer than 2000ms.

We'll probably end up letting some of these slide (pausing a background
or worker thread isn't necessarily a UX issue), but pausing the UI
thread is.

Luckily, we're able to use async APIs for most things. The remaining
things (like working with log files over IPC) we use a `Task.detached`
for.
2025-02-11 04:55:55 +00:00
Thomas Eizinger
b04d44a711 fix(website): make changelog more typesafe (#8084)
We currently have a bug in our changelog where the wrong download links
are being rendered for the Windows GUI client because we are incorrectly
matching on the title.

To fix this, we stop matching on the title and instead pass an `OS` enum
in the respective changelog components that need to differentiate
between OS-specific entries.
2025-02-11 04:55:42 +00:00
Thomas Eizinger
d7ebd07183 fix(linux): check for correct sign of netlink error code (#8087)
We've previously tried to handle the "No such process" error from
netlink when it tries to remove a route that no longer exists. What we
failed to do is use the correct sign for the error code as netlink
errors are always negative, yet when printed, the are positive numbers.
2025-02-11 04:47:51 +00:00
Thomas Eizinger
b193dd91f6 fix(windows): don't warn on disabled IP stack (#8086)
When an IP stack is programmatically disabled, such as with:

> reg add
"HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Tcpip6\Parameters"
/v DisabledComponents /t REG_DWORD /d 255 /f

Attempting to interact with this IP stack will yield "NOT_FOUND" errors.
These aren't worth reporting to Sentry because there isn't much we can
do about it.
2025-02-11 04:37:17 +00:00
Thomas Eizinger
c9b9fb0e6c feat(relay): add SOFTWARE attribute (#8076)
Adding a `SOFTWARE` attribute is recommended by the spec and will allow
us to identify from client logs, which version of the relay we are
talking to.
2025-02-11 03:34:38 +00:00
Jamil
feb1ec5e17 chore: Update client URLs & redirects for consistency (#8056)
Whenever changing a URL we care about, we add an entry in
`website/redirects.js` to avoid breaking links to the old page. Most
search engines reindex these after 1 year, but other websites and places
won't, so we should generally keep them indefinitely since they don't
cost us much to keep around.
2025-02-11 03:30:41 +00:00
Thomas Eizinger
436b502eab fix(windows): handle disabled IPv6 stack gracefully (#8083)
Fixes: #8049.
2025-02-11 03:21:32 +00:00
Thomas Eizinger
c5381b0e54 fix(telemetry): always clear previous Sentry session (#8075)
We have a bug in our Rust telemetry code where starting a new telemetry
session for an **unsupported** environment doesn't stop the previous one
if one already exists.

This results in very confusing Sentry issues that cannot be correlated
to our infrastructure.
2025-02-11 00:54:35 +00:00
Thomas Eizinger
f48df7585c refactor(windows): de-duplicate Win32 error codes (#8071)
The errors returned from Win32 API calls are currently duplicated in
several places. To makes it error-prone to handle them correctly. With
this PR, we de-duplicate this and add proper docs and links for further
reading to them.

We also fix a case where we would currently fail to set IP addresses for
our tunnel interface if the IP stack is not supported.
2025-02-10 23:33:06 +00:00
Jamil
e59aa0c93f chore: Hide internal commands/flags in headless clients (#8055)
These are just noise for the user and only used internally in Firezone.
2025-02-10 22:38:31 +00:00
Jamil
e8384ea5b0 refactor(apple): Make IPC calls async, bubbling errors (#8062)
`fetchResources` is an IPC call, and we can use
`withCheckedThrowingContinuation` like the others to yield while we wait
for the provider to respond.

The particular sentry issue related to this isn't because we are
necessarily blocking the task thread, rather, I suspect it's when
applying the fetched Resources to the UI that we're slow. There isn't
much we can do about this, but this PR will only help.

Because we're using a timer that fires off a closure to do this, we
still use a `callback` inside the timer to actually set the Resources on
the main `Store`, which updates the UI.

Unfortunately refactoring these IPC calls lead to somewhat of a ball of
yarn, so the best way to summarize the spirit of this PR is:

- Ensure IPC calls use `withCheckedThrowingContinuation` where possible
- Thusly, marking these functions `async throws`
- Bubble these errors up the view where we can ultimately decide what to
do with them
- Keep VPN state management and conditional logic based on `NEVPNStatus`
in the vpnConfigurationManager
2025-02-10 22:38:05 +00:00
Thomas Eizinger
786064ca40 chore(gui-client): reuse release-version constant (#8074)
This constant already defines the same string:
36f5eee99d/rust/gui-client/src-common/src/lib.rs (L19)
2025-02-10 22:24:08 +00:00
Thomas Eizinger
a0c96f7899 refactor(windows): don't fail install on missing IPC service (#8072)
In order to test changes to the IPC service on Windows more easily, the
IPC service binary offers an `install` command that installs a new
"Debug" IPC service. Prior to that, the previous is uninstalled.

This doesn't work if one doesn't have a previous "Debug" IPC service so
the `install` command only works for devs that have at least run it once
with that part of the function commented out. To improve this Dev UX, we
don't abort if we can't uninstall the previous one.
2025-02-10 22:01:01 +00:00
Thomas Eizinger
5b236408b8 chore(relay): log warn if we can't authenticate error response (#8073)
There should be a `Username` attribute in every request that is worth
sending an error back, if there isn't we have a bug somewhere.

Related: https://firezone-inc.sentry.io/issues/6275631126/.
2025-02-10 22:00:23 +00:00
oddlama
62ece23968 chore(portal): harden systemd relay example (#8045)
This adds hardening to the relay example systemd service shown in the
admin portal. Instead of running the service as root to download the
relay binary, we can let systemd manage the state directory and run with
lower privileges at all times.

I've also removed a shell injection which would in theory allow a
malicious github api server to run commands as root in the pre start
phase.

That being said I have no idea how this script is intended to function,
since it downloads the relay binary from the latest release on GitHub
which currently is a `gui-client` release without any relay binaries
attached.
2025-02-10 14:04:30 -08:00
Jamil
eb3c269d05 ci: Publish headless client 1.4.2 (#8080)
Publishes the headless client 1.4.2, now with Windows support.

Resolves: #3782
2025-02-10 19:10:36 +00:00
Jamil
5bac3f5ec2 fix(infra): Don't send more/faster metrics than Google accepts (#8028)
We are getting quite a few of these warnings on prod:

```
{400, "{\n  \"error\": {\n    \"code\": 400,\n    \"message\": \"One or more TimeSeries could not be written: timeSeries[0-39]: write for resource=gce_instance{zone:us-east1-d,instance_id:2678918148122610092} failed with: One or more points were written more frequently than the maximum sampling period configured for the metric.\",\n    \"status\": \"INVALID_ARGUMENT\",\n    \"details\": [\n      {\n        \"@type\": \"type.googleapis.com/google.monitoring.v3.CreateTimeSeriesSummary\",\n        \"totalPointCount\": 40,\n        \"successPointCount\": 31,\n        \"errors\": [\n          {\n            \"status\": {\n              \"code\": 9\n            },\n            \"pointCount\": 9\n          }\n        ]\n      }\n    ]\n  }\n}\n"}
```

Since the point count is _much_ less than our flush buffer size of 1000,
we can only surmise the limit we're hitting is the flush interval.

The telemetry metrics reporter is run on each node, so we run the risk
of violating Google's API limit regardless of what a single node's
`@flush_interval` is set to.

To solve this, we use a new table `telemetry_reporter_logs` that stores
the last time a particular `flush` occurred for a reporter module. This
tracks global state as to when the last flush occurred, and if too
recent, the timer-based flush is call is `no-op`ed until the next one.

**Note**: The buffer-based `flush` is left unchanged, this will always
be called when `buffer_size > max_buffer_size`.
2025-02-10 18:21:40 +00:00
Jamil
60ab106b67 chore(infra): Update otel-collector image to 0.119.0 (#8059)
We are quite a few versions behind.

The changelog lists a good amount of [Breaking API
changes](https://github.com/open-telemetry/opentelemetry-collector/releases),
but rather than enumerate all of those, or forever stay on the same
(ancient) version, I thought it would be a good idea to flex the upgrade
muscle here and see where it lands us on staging.
2025-02-10 16:47:05 +00:00
dependabot[bot]
5013f9b9c6 build(deps): bump sd-notify from 0.4.3 to 0.4.5 in /rust (#8078)
Bumps [sd-notify](https://github.com/lnicola/sd-notify) from 0.4.3 to
0.4.5.
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/lnicola/sd-notify/blob/master/CHANGELOG.md">sd-notify's
changelog</a>.</em></p>
<blockquote>
<h2>[0.4.5] - 2025-01-18</h2>
<h3>Fixed</h3>
<ul>
<li>fixed a dubious transmute between different slice types</li>
</ul>
<h2>[0.4.4] - 2025-01-16</h2>
<h3>Added</h3>
<ul>
<li>added <code>NotifyState::MonotonicUsec</code>, for use with
<code>Type=notify-reload</code></li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="70a941baf1"><code>70a941b</code></a>
Bump to 0.4.5</li>
<li><a
href="6958ce12e4"><code>6958ce1</code></a>
Merge pull request <a
href="https://redirect.github.com/lnicola/sd-notify/issues/15">#15</a>
from tbu-/pr_slice_transmute</li>
<li><a
href="1e938f2fd5"><code>1e938f2</code></a>
Use <code>slice::from_raw_parts</code> instead of
<code>mem::transmute</code></li>
<li><a
href="cb4459a4bb"><code>cb4459a</code></a>
Prepare for new release</li>
<li><a
href="8eb2c5cab3"><code>8eb2c5c</code></a>
Add NotifyState::MonotonicUsec and helper</li>
<li><a
href="5462699164"><code>5462699</code></a>
Add NotifyState::MonotonicUsec and helper</li>
<li><a
href="6990e3733f"><code>6990e37</code></a>
Fix clippy warnings</li>
<li>See full diff in <a
href="https://github.com/lnicola/sd-notify/compare/v0.4.3...v0.4.5">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=sd-notify&package-manager=cargo&previous-version=0.4.3&new-version=0.4.5)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-10 10:48:29 +00:00
dependabot[bot]
c1f8804d6d build(deps): bump clap from 4.5.21 to 4.5.28 in /rust (#8079)
Bumps [clap](https://github.com/clap-rs/clap) from 4.5.21 to 4.5.28.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/clap-rs/clap/releases">clap's
releases</a>.</em></p>
<blockquote>
<h2>v4.5.28</h2>
<h2>[4.5.28] - 2025-02-03</h2>
<h3>Features</h3>
<ul>
<li><em>(derive)</em> Unstable support for full markdown syntax for doc
comments, enabled with <code>unstable-markdown</code></li>
</ul>
<h2>v4.5.27</h2>
<h2>[4.5.27] - 2025-01-20</h2>
<h3>Documentation</h3>
<ul>
<li>Iterate on tutorials and reference based on feedback</li>
</ul>
<h2>v4.5.26</h2>
<h2>[4.5.26] - 2025-01-09</h2>
<h3>Fixes</h3>
<ul>
<li><em>(error)</em> Reduce binary size with the
<code>suggestions</code> feature</li>
</ul>
<h2>v4.5.25</h2>
<h2>[4.5.25] - 2025-01-09</h2>
<h3>Fixes</h3>
<ul>
<li><em>(help)</em> Reduce binary size</li>
</ul>
<h2>v4.5.24</h2>
<h2>[4.5.24] - 2025-01-07</h2>
<h3>Fixes</h3>
<ul>
<li><em>(parser)</em> Correctly handle defaults with
<code>ignore_errors(true)</code> and when a suggestion is provided for
an unknown argument</li>
</ul>
<h2>v4.5.23</h2>
<h2>[4.5.23] - 2024-12-05</h2>
<h3>Fixes</h3>
<ul>
<li><em>(parser)</em> When check <code>allow_negative_numbers</code>,
allow <code>E</code> again</li>
</ul>
<h2>v4.5.22</h2>
<h2>[4.5.22] - 2024-12-03</h2>
<h3>Fixes</h3>
<ul>
<li><em>(assert)</em> Catch bugs with arguments requiring themself</li>
</ul>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/clap-rs/clap/blob/master/CHANGELOG.md">clap's
changelog</a>.</em></p>
<blockquote>
<h2>[4.5.28] - 2025-02-03</h2>
<h3>Features</h3>
<ul>
<li><em>(derive)</em> Unstable support for full markdown syntax for doc
comments, enabled with <code>unstable-markdown</code></li>
</ul>
<h2>[4.5.27] - 2025-01-20</h2>
<h3>Documentation</h3>
<ul>
<li>Iterate on tutorials and reference based on feedback</li>
</ul>
<h2>[4.5.26] - 2025-01-09</h2>
<h3>Fixes</h3>
<ul>
<li><em>(error)</em> Reduce binary size with the
<code>suggestions</code> feature</li>
</ul>
<h2>[4.5.25] - 2025-01-09</h2>
<h3>Fixes</h3>
<ul>
<li><em>(help)</em> Reduce binary size</li>
</ul>
<h2>[4.5.24] - 2025-01-07</h2>
<h3>Fixes</h3>
<ul>
<li><em>(parser)</em> Correctly handle defaults with
<code>ignore_errors(true)</code> and when a suggestion is provided for
an unknown argument</li>
</ul>
<h2>[4.5.23] - 2024-12-05</h2>
<h3>Fixes</h3>
<ul>
<li><em>(parser)</em> When check <code>allow_negative_numbers</code>,
allow <code>E</code> again</li>
</ul>
<h2>[4.5.22] - 2024-12-03</h2>
<h3>Fixes</h3>
<ul>
<li><em>(assert)</em> Catch bugs with arguments requiring themself</li>
</ul>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="257d7812b9"><code>257d781</code></a>
chore: Release</li>
<li><a
href="06c5f5f329"><code>06c5f5f</code></a>
docs: Update changelog</li>
<li><a
href="6ac153557c"><code>6ac1535</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/5733">#5733</a>
from epage/bin</li>
<li><a
href="a7a8f93d6b"><code>a7a8f93</code></a>
fix(complete): Strip wrappers for running completer</li>
<li><a
href="b2c8e445aa"><code>b2c8e44</code></a>
feat(complete): Allow user to override bin/completer</li>
<li><a
href="21c9892efe"><code>21c9892</code></a>
chore: Release</li>
<li><a
href="0c8bceb3e9"><code>0c8bceb</code></a>
docs: Update changelog</li>
<li><a
href="d8f102a18c"><code>d8f102a</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/5732">#5732</a>
from epage/consistent</li>
<li><a
href="c92fca3a8f"><code>c92fca3</code></a>
docs(complete): Clarify CompleteEnv's Shell trait</li>
<li><a
href="5ca60e9079"><code>5ca60e9</code></a>
Merge pull request <a
href="https://redirect.github.com/clap-rs/clap/issues/5731">#5731</a>
from epage/bash</li>
<li>Additional commits viewable in <a
href="https://github.com/clap-rs/clap/compare/clap_complete-v4.5.21...clap_complete-v4.5.28">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=clap&package-manager=cargo&previous-version=4.5.21&new-version=4.5.28)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-10 10:47:39 +00:00
Thomas Eizinger
105c984512 fix(rust): only use ANSI colors if the output supports it (#8070)
Fixes: #8054.
2025-02-10 04:39:18 +00:00
Jamil
0e990d29d3 refactor(apple): Annotate update resources callback @MainActor (#8069)
Followup to the discussion on
https://github.com/firezone/firezone/pull/8064. By annotating the
callback that updates our Resources `@MainActor`, the compiler will
correctly warn us when we call it from a non-isolated context.
2025-02-10 03:53:22 +00:00
Thomas Eizinger
fdb7631529 feat(gui-client): gracefully exit GUI on graceful IPC shutdown (#8035)
When the IPC service gets terminated gracefully, the user must have
initiated some kind of action, be it an upgrade or an explicit "Stop the
service". In that case, there is no point in displaying an alert with an
info / error message as the user already knows that they are stopping
Firezone. In order to not fatigue the user with alerts, we exit the GUI
with a toast notification when the IPC service shuts down gracefully.
Toast notifications do not grab the users attention, allowing them to
continue what they are doing while still being notified that their
Firezone client is now disconnected.

Fixes: #6232.
2025-02-10 03:33:24 +00:00
Jamil
36f5eee99d fix(apple): Prevent dupe resources timer scheduling (#8066)
If we receive two `.connected` status change updates from the system in
a row, we'll incorrectly schedule an additional timer, and the handle to
the first one will be lost.

This causes a memory leak because we'll then never call the first
timer's `invalidate()` function in the `endUpdatingResources` call.
2025-02-09 23:12:25 +00:00
Jamil
ce81dc5e98 fix(apple): Ensure resources are updated on MainActor (#8064)
This fixes a bug introduced in db655dd171 that could lead to a crash or
undefined behavior because it potentially updates resources (a
`@Published` object) from a background thread.

UI updates must occur on the main thread only.
2025-02-09 22:40:53 +00:00
Jamil
7dc6e36fb0 Revert 'fix(apple): Make Favorites load/save async' (#8068)
Turns out I was wrong about UserDefaults - they're persisted, but backed
by an in-memory cache. The persisting is handled asynchronously, so this
is unlikely to be the culprit of
https://firezone-inc.sentry.io/issues/6225229650/?project=4508175177023488&query=is%3Aunresolved%20issue.priority%3A%5Bhigh%2C%20medium%5D&referrer=issue-stream&statsPeriod=30d&stream_index=1

More likely it has to do with some other synchronous I/O, so the search
continues. Unfortunately we don't have great backtraces for this issue
because it looks like the hang is happening outside the scope of our
code, and seems to be macOS-only in low memory conditions.

Reverts firezone/firezone#8060
2025-02-09 14:52:31 -08:00
Jamil
cd85d7e8f9 fix(apple): Make Favorites load/save async (#8060)
The `load` and `save` functions in `Favorites` perform disk I/O and
should be wrapped with `withCheckedContinuation` in order to allow these
to be managed by the async runtime.

This was causing a detected hang on some devices with limited disk I/O
resources.
2025-02-09 12:02:33 +00:00
Jamil
55802cdf3a fix(apple): Make sign in error modal async (#8061)
So it turns out we can get around the whole modal-blocking issue by
wrapping the `runModal()` call in `withCheckedContinuation`.

The key takeaway here is that `withCheckedContinuation` can be used to
wrap calls that can block I/O, marking them async, and allowing the Task
executor to do other useful work. This can even take place on on the
main thread.

Bear in mind `withCheckedContinuation` (and friends) *will not* prevent
blocking the task executor if the code being called is CPU-bottlenecked
in nature, such as calculating prime numbers or something. In those
cases, even `Task.detached` will cause Sentry to report `App Hanging`
alerts.

In short, only `Task.detached` when the I/O-related work to perform does
not depend on the current context and can be executed completely
independently of the parent, such as downloading image files in the
background or something.
2025-02-09 02:14:26 +00:00
Jamil
96f61e4bdb docs: Add headless Windows client (#8052)
This adds the following for the headless Windows client:

- website download redirects to use for permalinks
- Windows headless client user guide

It also cleans up old references and a few minor related things I found
while working on this.
2025-02-09 01:50:39 +00:00
Jamil
3d9c731ff4 docs: Update AWS example to use Internet Gateway (#8051)
Updates the docs to use `Internet Gateway` terminology where applicable.

Related: https://github.com/firezone/terraform-aws-gateway/pull/4
2025-02-08 23:25:31 +00:00
Jamil
8d5472544c ci: Sign the windows headless client (#8057)
As a followup to #8041, we need to sign the Windows headless client with
our production EV Code Signing cert.
2025-02-08 21:31:30 +00:00
Jamil
11b9916784 fix(ci): Use correct script path from rust/ dir (#8053)
Fixes a bug introduced in #8041
2025-02-08 06:52:33 -08:00
Jamil
b8852b3e7a ci: attach Windows headless client to release (#8041)
This publishes the windows headless client using the same convention set
forth by the linux headless client.

Docs and website changes will come in a subsequent PR.

Related: #3782
Resolves: #8046
2025-02-08 13:51:56 +00:00
Jamil
ff07f10759 chore(portal): Remove GCP alerting for application errors (#8040)
As discussed with @bmanifold, we're moving forward with the following
monitoring strategy:

For infra alerts, stick with GCP.

For application-level alerts, use Sentry.

Since we already have Sentry configured and working on staging, this PR
removes the "Errors in logs" alert since we will be receiving this in
Sentry going forward.
2025-02-07 15:12:39 +00:00
Jamil
3f62eff4a1 feat(portal): add configuration for the healthz port (#8020) (#8030)
This is required to run multiple components on a single machine (even if
the processes are sandboxed), since they will share a network namespace
and thus cannot bind to the same port.

Currently port `4000` is hardcoded, this PR allows this to be configured
by an environment variable.

---------

Co-authored-by: oddlama <oddlama@oddlama.org>
2025-02-07 10:35:05 +00:00
Thomas Eizinger
e3e6634790 chore: make all Rust code compile on Windows (#8036)
Developing on Windows is much easier if all Rust code compiles without
errors or warnings because you can "trust" your IDE that your code is
error free if it says "0 errors; 0 warnings". We are not far off from
achieving this!

Apart from the "graceful termination" feature in the relay, both the
relay and gateway should actually also work on Windows just fine, thanks
to the platform-agnostic abstractions we have been building up for the
GUI and headless client.
2025-02-06 14:25:10 +00:00
Thomas Eizinger
6f70ebe2b8 fix(gui-client): graceful shutdown of IPC service on Windows (#8034)
When the IPC service is shutdown gracefully (i.e. purposely), we send a
`TerminatingGracefully` message of the IPC channel. This allows the GUI
to handle this case differently from the a crash.

On Linux, this is achieved by reacting to signals that are sent to the
IPC process. Windows however doesn't send any signals to services.
Instead, we get an event that we are being shutdown.

Currently, this event is handled separately from the signal handler and
the signal handler does nothing on Windows. To make this more uniform
and allow graceful shutdown of the IPC service on Windows, we introduce
a 2nd constructor to the `Terminate` signal abstraction that is already
hooked up with the correct logic here.
2025-02-06 14:21:39 +00:00
Thomas Eizinger
d2e9b09874 refactor(rust): stringify errors early (#8033)
As it turns out, the effort in #7104 was not a good idea. By logging
errors as values, most of our Sentry reports all have the same title and
thus cannot be differentiated from within the overview at all. To fix
this, we stringify errors with all their sources whenever they got
logged. This ensures log messages are unique and all Sentry issues will
have a useful title.
2025-02-06 14:18:35 +00:00
Jamil
945d40e7f9 docs: Add docs on WinTUN reset (#8032)
This is a fix for #7962 caused by a recent Windows 11 update reported by
users in our Discord chat.
2025-02-06 14:16:54 +00:00
Jamil
cdb669f6c5 chore(dev): Use postgres:15 for docker-compose.yml (#8029)
This will ensure we're using the latest Postgres major, which should
more closely track staging/prod.
2025-02-06 14:16:34 +00:00
Jamil
a93f40befd chore(portal): Bump elixir to 1.18.2 (#8009)
This is mostly to stay up to date with current Elixir and benefit from
the new included [JSON parser](https://hexdocs.pm/elixir/JSON.html).

Removing `Jason` in favor of the embedded `JSON` parser is saved for a
[future PR](https://github.com/firezone/firezone/issues/8011).

It found a couple type violations which were simple to fix, and some
formatting changes.
2025-02-05 23:52:58 +00:00
Jamil
006ea4c6fd fix(infra): Inline sentry logging config (#8031)
It appears that something is initializing the Sentry.LoggerHandler
before we try to load it when starting:

```
Invalid logger handler config: {:logger,
 {:invalid_handler, {:function_not_exported, {Sentry.LoggerHandler, :log, 2}}}}
```

This doesn't seem to actually inhibit the Sentry logger at all,
presumably because it initializes just fine in the application start
callback.

Instead of defining the config in the `config/` directory, we can pass
it directly to `:logger` on start which solves the above issue.
2025-02-05 23:36:06 +00:00
Jamil
d1761e5a5d fix(infra): Bust cache for already-reported min/max metrics (#8026)
On staging (only), we see these logs spammed:


```
{400, "{\n  \"error\": {\n    \"code\": 400,\n    \"message\": \"One or more TimeSeries could not be written: timeSeries[22]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/queue_time/min must be CUMULATIVE, but is GAUGE.; timeSeries[11]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/query_time/max must be CUMULATIVE, but is GAUGE.; timeSeries[8]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/idle_time/max must be CUMULATIVE, but is GAUGE.; timeSeries[7]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/idle_time/min must be CUMULATIVE, but is GAUGE.; timeSeries[10]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/query_time/min must be CUMULATIVE, but is GAUGE.; timeSeries[14]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/query_time/max must be CUMULATIVE, but is GAUGE.; timeSeries[13]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/query_time/min must be CUMULATIVE, but is GAUGE.; timeSeries[16]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/query_time/min must be CUMULATIVE, but is GAUGE.; timeSeries[23]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/queue_time/max must be CUMULATIVE, but is GAUGE.; timeSeries[20]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/query_time/max must be CUMULATIVE, but is GAUGE.; timeSeries[19]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/query_time/min must be CUMULATIVE, but is GAUGE.; timeSeries[17]: Metric kind for metric custom.googleapis.com/elixir/domain/repo/query/query_time/max must be CUMULATIVE, but is GAUGE.\",\n    \"status\": \"INVALID_ARGUMENT\",\n    \"details\": [\n      {\n        \"@type\": \"type.googleapis.com/google.monitoring.v3.CreateTimeSeriesSummary\",\n        \"totalPointCount\": 36,\n        \"successPointCount\": 24,\n        \"errors\": [\n          {\n            \"status\": {\n              \"code\": 3\n            },\n            \"pointCount\": 12\n          }\n        ]\n      }\n    ]\n  }\n}\n"}
```

This does not happen on prod. As far as I can tell, GCP will cache the
initial metric kind used when the metric ID was first used, which
appears to be `CUMULATIVE` here.

The correct metric kind for these is `GAUGE` since they're reporting a
min/max value.

Since GCP doesn't support resetting the auto-defined metric kind of a
particular metric ID, we need to alter the ID to "bust" the cache and
create a new definition.
2025-02-05 18:30:04 +00:00
dependabot[bot]
7a5354ba36 build(deps-dev): bump tailwindcss from 3.4.17 to 4.0.3 in /rust/gui-client (#7995)
Bumps
[tailwindcss](https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss)
from 3.4.17 to 4.0.3.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/tailwindlabs/tailwindcss/releases">tailwindcss's
releases</a>.</em></p>
<blockquote>
<h2>v4.0.3</h2>
<h3>Fixed</h3>
<ul>
<li>Fix incorrect removal of <code>@import url();</code> (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16144">#16144</a>)</li>
</ul>
<h2>v4.0.2</h2>
<h3>Fixed</h3>
<ul>
<li>Only generate positive <code>grid-cols-*</code> and
<code>grid-rows-*</code> utilities (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16020">#16020</a>)</li>
<li>Ensure escaped theme variables are handled correctly (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16064">#16064</a>)</li>
<li>Ensure we process Tailwind CSS features when only using
<code>@reference</code> or <code>@variant</code> (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16057">#16057</a>)</li>
<li>Refactor gradient implementation to work around <a
href="https://redirect.github.com/prettier/prettier/issues/17058">prettier/prettier#17058</a>
(<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16072">#16072</a>)</li>
<li>Vite: Ensure hot-reloading works with SolidStart setups (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16052">#16052</a>)</li>
<li>Vite: Fix a crash when starting the development server in SolidStart
setups (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16052">#16052</a>)</li>
<li>Vite: Don't rebase URLs that appear to be aliases (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16078">#16078</a>)</li>
<li>Vite: Transform <code>&lt;style&gt;</code> blocks in HTML files (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16069">#16069</a>)</li>
<li>Prevent camel-casing CSS custom properties added by JavaScript
plugins (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16103">#16103</a>)</li>
<li>Do not emit <code>@keyframes</code> in <code>@theme reference</code>
(<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16120">#16120</a>)</li>
<li>Discard invalid declarations when parsing CSS (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16093">#16093</a>)</li>
<li>Do not emit empty CSS rules and at-rules (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16121">#16121</a>)</li>
<li>Handle <code>@variant</code> when at the top-level of a stylesheet
(<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16129">#16129</a>)</li>
</ul>
<h2>v4.0.1</h2>
<h3>Added</h3>
<ul>
<li>Include <code>:open</code> pseudo-class in existing
<code>open</code> variant (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15349">#15349</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>Remove invalid <code>min-w/h-none</code> utilities (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15845">#15845</a>)</li>
<li>Discard CSS variable shorthand utilities that don't use valid CSS
variables (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15738">#15738</a>)</li>
<li>Ensure font-size utilities with <code>none</code> modifier have a
line-height set e.g. <code>text-sm/none</code> (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15921">#15921</a>)</li>
<li>Ensure font-size utilities with unknown modifier don't generate CSS
(<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15921">#15921</a>)</li>
<li>Don’t suggest font weight utilities more than once (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15857">#15857</a>)</li>
<li>Suggest container query variants (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15857">#15857</a>)</li>
<li>Disable bare value suggestions when not using the
<code>--spacing</code> variable (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15857">#15857</a>)</li>
<li>Ensure suggested classes are properly sorted (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15857">#15857</a>)</li>
<li>Don’t look at .gitignore files outside initialized repos (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15941">#15941</a>)</li>
<li>Find utilities when using the Svelte class shorthand syntax across
multiple lines (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15974">#15974</a>)</li>
<li>Find utilities when using the Angular class shorthand syntax (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15974">#15974</a>)</li>
<li>Find utilities when using functions inside arrays (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15974">#15974</a>)</li>
<li>Ensure that <code>@tailwindcss/browser</code> does not pollute the
global namespace (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15978">#15978</a>)</li>
<li>Ensure that <code>tailwind-merge</code> is not scanned when using
the Vite plugin (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16005">#16005</a>)</li>
<li>Ensure CSS theme variables are available within shadow roots (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15975">#15975</a>)</li>
<li>Fix crash when project lives in the <code>/</code> directory (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15988">#15988</a>)</li>
<li>Ensure custom variants have a non-empty selector list (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16009">#16009</a>)</li>
<li><em>Upgrade</em>: Ensure JavaScript config files on different drives
are correctly migrated (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15927">#15927</a>)</li>
<li><em>Upgrade</em>: Migrate <code>leading-[1]</code> to
<code>leading-none</code> (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16004">#16004</a>)</li>
<li><em>Upgrade</em>: Do not migrate arbitrary leading utilities to bare
values (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16004">#16004</a>)</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/tailwindlabs/tailwindcss/blob/main/CHANGELOG.md">tailwindcss's
changelog</a>.</em></p>
<blockquote>
<h2>[4.0.3] - 2025-02-01</h2>
<h3>Fixed</h3>
<ul>
<li>Fix incorrect removal of <code>@import url();</code> (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16144">#16144</a>)</li>
</ul>
<h2>[4.0.2] - 2025-01-31</h2>
<h3>Fixed</h3>
<ul>
<li>Only generate positive <code>grid-cols-*</code> and
<code>grid-rows-*</code> utilities (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16020">#16020</a>)</li>
<li>Ensure escaped theme variables are handled correctly (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16064">#16064</a>)</li>
<li>Ensure we process Tailwind CSS features when only using
<code>@reference</code> or <code>@variant</code> (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16057">#16057</a>)</li>
<li>Refactor gradient implementation to work around <a
href="https://redirect.github.com/prettier/prettier/issues/17058">prettier/prettier#17058</a>
(<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16072">#16072</a>)</li>
<li>Vite: Ensure hot-reloading works with SolidStart setups (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16052">#16052</a>)</li>
<li>Vite: Fix a crash when starting the development server in SolidStart
setups (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16052">#16052</a>)</li>
<li>Vite: Don't rebase URLs that appear to be aliases (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16078">#16078</a>)</li>
<li>Vite: Transform <code>&lt;style&gt;</code> blocks in HTML files (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16069">#16069</a>)</li>
<li>Prevent camel-casing CSS custom properties added by JavaScript
plugins (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16103">#16103</a>)</li>
<li>Do not emit <code>@keyframes</code> in <code>@theme reference</code>
(<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16120">#16120</a>)</li>
<li>Discard invalid declarations when parsing CSS (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16093">#16093</a>)</li>
<li>Do not emit empty CSS rules and at-rules (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16121">#16121</a>)</li>
<li>Handle <code>@variant</code> when at the top-level of a stylesheet
(<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16129">#16129</a>)</li>
</ul>
<h2>[4.0.1] - 2025-01-29</h2>
<h3>Added</h3>
<ul>
<li>Include <code>:open</code> pseudo-class in existing
<code>open</code> variant (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15349">#15349</a>)</li>
</ul>
<h3>Fixed</h3>
<ul>
<li>Remove invalid <code>min-w/h-none</code> utilities (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15845">#15845</a>)</li>
<li>Discard CSS variable shorthand utilities that don't use valid CSS
variables (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15738">#15738</a>)</li>
<li>Ensure font-size utilities with <code>none</code> modifier have a
line-height set e.g. <code>text-sm/none</code> (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15921">#15921</a>)</li>
<li>Ensure font-size utilities with unknown modifier don't generate CSS
(<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15921">#15921</a>)</li>
<li>Don’t suggest font weight utilities more than once (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15857">#15857</a>)</li>
<li>Suggest container query variants (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15857">#15857</a>)</li>
<li>Disable bare value suggestions when not using the
<code>--spacing</code> variable (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15857">#15857</a>)</li>
<li>Ensure suggested classes are properly sorted (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15857">#15857</a>)</li>
<li>Don’t look at .gitignore files outside initialized repos (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15941">#15941</a>)</li>
<li>Find utilities when using the Svelte class shorthand syntax across
multiple lines (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15974">#15974</a>)</li>
<li>Find utilities when using the Angular class shorthand syntax (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15974">#15974</a>)</li>
<li>Find utilities when using functions inside arrays (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15974">#15974</a>)</li>
<li>Ensure that <code>@tailwindcss/browser</code> does not pollute the
global namespace (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15978">#15978</a>)</li>
<li>Ensure that <code>tailwind-merge</code> is not scanned when using
the Vite plugin (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16005">#16005</a>)</li>
<li>Ensure CSS theme variables are available within shadow roots (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15975">#15975</a>)</li>
<li>Fix crash when project lives in the <code>/</code> directory (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15988">#15988</a>)</li>
<li>Ensure custom variants have a non-empty selector list (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/16009">#16009</a>)</li>
<li><em>Upgrade</em>: Ensure JavaScript config files on different drives
are correctly migrated (<a
href="https://redirect.github.com/tailwindlabs/tailwindcss/pull/15927">#15927</a>)</li>
</ul>
<!-- raw HTML omitted -->
</blockquote>
<p>... (truncated)</p>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="b7c3f50143"><code>b7c3f50</code></a>
Prepare v4.0.3 (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16146">#16146</a>)</li>
<li><a
href="b7436f8b59"><code>b7436f8</code></a>
Fix <code>@import url()</code> being stripped (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16144">#16144</a>)</li>
<li><a
href="50bafce756"><code>50bafce</code></a>
Prepare for v4.0.2 release (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16131">#16131</a>)</li>
<li><a
href="4052eb24bf"><code>4052eb2</code></a>
Allow <code>@variant</code> to be used at the top-level (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16129">#16129</a>)</li>
<li><a
href="7f1d0970c3"><code>7f1d097</code></a>
Do not emit empty rules/at-rules (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16121">#16121</a>)</li>
<li><a
href="35a5e8cb64"><code>35a5e8c</code></a>
Discard invalid declarations when parsing CSS (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16093">#16093</a>)</li>
<li><a
href="60e61950b9"><code>60e6195</code></a>
Ensure escaped theme variables are handled correctly (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16064">#16064</a>)</li>
<li><a
href="3aa0e494bf"><code>3aa0e49</code></a>
Do not emit <code>@keyframes</code> in <code>@theme reference</code> (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16120">#16120</a>)</li>
<li><a
href="88c890615a"><code>88c8906</code></a>
Prevent modifying CSS variables in plugins (<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16103">#16103</a>)</li>
<li><a
href="224294122b"><code>2242941</code></a>
Refactor gradient implementation to work around <a
href="https://redirect.github.com/prettier/prettier/issues/17058">prettier/prettier#17058</a>
(<a
href="https://github.com/tailwindlabs/tailwindcss/tree/HEAD/packages/tailwindcss/issues/16072">#16072</a>)</li>
<li>Additional commits viewable in <a
href="https://github.com/tailwindlabs/tailwindcss/commits/v4.0.3/packages/tailwindcss">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=tailwindcss&package-manager=npm_and_yarn&previous-version=3.4.17&new-version=4.0.3)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-05 15:49:17 +00:00
Jamil
dec2b0ee81 fix(portal): Only configure Sentry.LoggerHandler once (#8025)
The applications within our umbrella are all joined into a single Erlang
cluster, and logger configuration is applied already to the entire
umbrella.

As such, registering the Sentry log handler in each application's
startup routine triggers duplicate handlers to be registered for the
cluster, resulting in warnings like this in GCP:

```
Event dropped due to being a duplicate of a previously-captured event.
```

As such, we can move the log handler configuration to the top-level
`:logger` key, under the `:logger` subkey for configuring a single
handler. We then load this handler config in the `domain` app only and
it applies to the entire cluster.
2025-02-05 13:41:19 +00:00
Jamil
9034628514 chore(infra): Reduce gateway size to e2-micro for prod (#8027)
`e2-micro` is what we use for Relays and should be more than capable to
use for our internal prod Gateways for accessing the prod env.

Cost savings is about 3-4x vs `n1-standard-1`.
2025-02-05 13:39:46 +00:00
dependabot[bot]
e63c702460 build(deps): bump log from 0.4.22 to 0.4.25 in /rust (#8006)
Bumps [log](https://github.com/rust-lang/log) from 0.4.22 to 0.4.25.
<details>
<summary>Release notes</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/log/releases">log's
releases</a>.</em></p>
<blockquote>
<h2>0.4.25</h2>
<h2>What's Changed</h2>
<ul>
<li>Revert loosening of kv cargo features by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/662">rust-lang/log#662</a></li>
<li>Prepare for 0.4.25 release by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/663">rust-lang/log#663</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/log/compare/0.4.24...0.4.25">https://github.com/rust-lang/log/compare/0.4.24...0.4.25</a></p>
<h2>0.4.24 (yanked)</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix up kv feature activation by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/659">rust-lang/log#659</a></li>
<li>Prepare for 0.4.24 release by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/660">rust-lang/log#660</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/log/compare/0.4.23...0.4.24">https://github.com/rust-lang/log/compare/0.4.23...0.4.24</a></p>
<h2>0.4.23 (yanked)</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix some typos by <a
href="https://github.com/Kleinmarb"><code>@​Kleinmarb</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/637">rust-lang/log#637</a></li>
<li>Add logforth to implementation by <a
href="https://github.com/tisonkun"><code>@​tisonkun</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/638">rust-lang/log#638</a></li>
<li>Add <code>spdlog-rs</code> link to README by <a
href="https://github.com/SpriteOvO"><code>@​SpriteOvO</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/639">rust-lang/log#639</a></li>
<li>Add correct lifetime to kv::Value::to_borrowed_str by <a
href="https://github.com/stevenroose"><code>@​stevenroose</code></a> in
<a
href="https://redirect.github.com/rust-lang/log/pull/643">rust-lang/log#643</a></li>
<li>docs: Add logforth as an impl by <a
href="https://github.com/tisonkun"><code>@​tisonkun</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/642">rust-lang/log#642</a></li>
<li>Add clang_log implementation by <a
href="https://github.com/DDAN-17"><code>@​DDAN-17</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/646">rust-lang/log#646</a></li>
<li>Bind lifetimes of &amp;str returned from Key by the lifetime of 'k
rather than the lifetime of the Key struct by <a
href="https://github.com/gbbosak"><code>@​gbbosak</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/648">rust-lang/log#648</a>
(reverted)</li>
<li>Fix up key lifetimes and add method to try get a borrowed key by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/653">rust-lang/log#653</a></li>
<li>Add Ftail implementation by <a
href="https://github.com/tjardoo"><code>@​tjardoo</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/652">rust-lang/log#652</a></li>
<li>Relax feature flag for value's std_support by <a
href="https://github.com/tisonkun"><code>@​tisonkun</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/657">rust-lang/log#657</a></li>
<li>Prepare for 0.4.23 release by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/656">rust-lang/log#656</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/Kleinmarb"><code>@​Kleinmarb</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/637">rust-lang/log#637</a></li>
<li><a href="https://github.com/tisonkun"><code>@​tisonkun</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/638">rust-lang/log#638</a></li>
<li><a href="https://github.com/SpriteOvO"><code>@​SpriteOvO</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/639">rust-lang/log#639</a></li>
<li><a
href="https://github.com/stevenroose"><code>@​stevenroose</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/643">rust-lang/log#643</a></li>
<li><a href="https://github.com/DDAN-17"><code>@​DDAN-17</code></a> made
their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/646">rust-lang/log#646</a></li>
<li><a href="https://github.com/gbbosak"><code>@​gbbosak</code></a> made
their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/648">rust-lang/log#648</a></li>
<li><a href="https://github.com/tjardoo"><code>@​tjardoo</code></a> made
their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/652">rust-lang/log#652</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/log/compare/0.4.22...0.4.23">https://github.com/rust-lang/log/compare/0.4.22...0.4.23</a></p>
</blockquote>
</details>
<details>
<summary>Changelog</summary>
<p><em>Sourced from <a
href="https://github.com/rust-lang/log/blob/master/CHANGELOG.md">log's
changelog</a>.</em></p>
<blockquote>
<h2>[0.4.25] - 2025-01-14</h2>
<h2>What's Changed</h2>
<ul>
<li>Revert loosening of kv cargo features by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/662">rust-lang/log#662</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/log/compare/0.4.24...0.4.25">https://github.com/rust-lang/log/compare/0.4.24...0.4.25</a></p>
<h2>[0.4.24] - 2025-01-11</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix up kv feature activation by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/659">rust-lang/log#659</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/log/compare/0.4.23...0.4.24">https://github.com/rust-lang/log/compare/0.4.23...0.4.24</a></p>
<h2>[0.4.23] - 2025-01-10 (yanked)</h2>
<h2>What's Changed</h2>
<ul>
<li>Fix some typos by <a
href="https://github.com/Kleinmarb"><code>@​Kleinmarb</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/637">rust-lang/log#637</a></li>
<li>Add logforth to implementation by <a
href="https://github.com/tisonkun"><code>@​tisonkun</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/638">rust-lang/log#638</a></li>
<li>Add <code>spdlog-rs</code> link to README by <a
href="https://github.com/SpriteOvO"><code>@​SpriteOvO</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/639">rust-lang/log#639</a></li>
<li>Add correct lifetime to kv::Value::to_borrowed_str by <a
href="https://github.com/stevenroose"><code>@​stevenroose</code></a> in
<a
href="https://redirect.github.com/rust-lang/log/pull/643">rust-lang/log#643</a></li>
<li>docs: Add logforth as an impl by <a
href="https://github.com/tisonkun"><code>@​tisonkun</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/642">rust-lang/log#642</a></li>
<li>Add clang_log implementation by <a
href="https://github.com/DDAN-17"><code>@​DDAN-17</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/646">rust-lang/log#646</a></li>
<li>Bind lifetimes of &amp;str returned from Key by the lifetime of 'k
rather than the lifetime of the Key struct by <a
href="https://github.com/gbbosak"><code>@​gbbosak</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/648">rust-lang/log#648</a></li>
<li>Fix up key lifetimes and add method to try get a borrowed key by <a
href="https://github.com/KodrAus"><code>@​KodrAus</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/653">rust-lang/log#653</a></li>
<li>Add Ftail implementation by <a
href="https://github.com/tjardoo"><code>@​tjardoo</code></a> in <a
href="https://redirect.github.com/rust-lang/log/pull/652">rust-lang/log#652</a></li>
</ul>
<h2>New Contributors</h2>
<ul>
<li><a href="https://github.com/Kleinmarb"><code>@​Kleinmarb</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/637">rust-lang/log#637</a></li>
<li><a href="https://github.com/tisonkun"><code>@​tisonkun</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/638">rust-lang/log#638</a></li>
<li><a href="https://github.com/SpriteOvO"><code>@​SpriteOvO</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/639">rust-lang/log#639</a></li>
<li><a
href="https://github.com/stevenroose"><code>@​stevenroose</code></a>
made their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/643">rust-lang/log#643</a></li>
<li><a href="https://github.com/DDAN-17"><code>@​DDAN-17</code></a> made
their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/646">rust-lang/log#646</a></li>
<li><a href="https://github.com/gbbosak"><code>@​gbbosak</code></a> made
their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/648">rust-lang/log#648</a></li>
<li><a href="https://github.com/tjardoo"><code>@​tjardoo</code></a> made
their first contribution in <a
href="https://redirect.github.com/rust-lang/log/pull/652">rust-lang/log#652</a></li>
</ul>
<p><strong>Full Changelog</strong>: <a
href="https://github.com/rust-lang/log/compare/0.4.22...0.4.23">https://github.com/rust-lang/log/compare/0.4.22...0.4.23</a></p>
</blockquote>
</details>
<details>
<summary>Commits</summary>
<ul>
<li><a
href="22be810729"><code>22be810</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/log/issues/663">#663</a>
from rust-lang/cargo/0.4.25</li>
<li><a
href="0279730123"><code>0279730</code></a>
prepare for 0.4.25 release</li>
<li><a
href="4099bcb357"><code>4099bcb</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/log/issues/662">#662</a>
from rust-lang/fix/cargo-features</li>
<li><a
href="36e7e3f696"><code>36e7e3f</code></a>
revert loosening of kv cargo features</li>
<li><a
href="2282191854"><code>2282191</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/log/issues/660">#660</a>
from rust-lang/cargo/0.4.24</li>
<li><a
href="2994f0a62c"><code>2994f0a</code></a>
prepare for 0.4.24 release</li>
<li><a
href="5fcb50eccd"><code>5fcb50e</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/log/issues/659">#659</a>
from rust-lang/fix/feature-builds</li>
<li><a
href="29fe9e60ff"><code>29fe9e6</code></a>
fix up feature activation</li>
<li><a
href="b1824f2c28"><code>b1824f2</code></a>
use cargo hack in CI to test all feature combinations</li>
<li><a
href="e6b643d591"><code>e6b643d</code></a>
Merge pull request <a
href="https://redirect.github.com/rust-lang/log/issues/656">#656</a>
from rust-lang/cargo/0.4.23</li>
<li>Additional commits viewable in <a
href="https://github.com/rust-lang/log/compare/0.4.22...0.4.25">compare
view</a></li>
</ul>
</details>
<br />


[![Dependabot compatibility
score](https://dependabot-badges.githubapp.com/badges/compatibility_score?dependency-name=log&package-manager=cargo&previous-version=0.4.22&new-version=0.4.25)](https://docs.github.com/en/github/managing-security-vulnerabilities/about-dependabot-security-updates#about-compatibility-scores)

Dependabot will resolve any conflicts with this PR as long as you don't
alter it yourself. You can also trigger a rebase manually by commenting
`@dependabot rebase`.

[//]: # (dependabot-automerge-start)
[//]: # (dependabot-automerge-end)

---

<details>
<summary>Dependabot commands and options</summary>
<br />

You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits
that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after
your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge
and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating
it. You can achieve the same result by closing it manually
- `@dependabot show <dependency name> ignore conditions` will show all
of the ignore conditions of the specified dependency
- `@dependabot ignore this major version` will close this PR and stop
Dependabot creating any more for this major version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop
Dependabot creating any more for this minor version (unless you reopen
the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop
Dependabot creating any more for this dependency (unless you reopen the
PR or upgrade to it yourself)


</details>

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-05 00:41:54 +00:00
Thomas Eizinger
a813833ef6 refactor(gui-client): simplify error handling of gui::run (#7958)
At present, the GUI client uses a monolithic `Error` enum that
represents all kinds of errors. Some of them are unused (see #7956).
Others are only used during startup, like the `deep_link` and
`WebViewNotInstalled` variants. This makes it difficult to write correct
error handling code.

In addition to remove certain variants in #7965, this PR refactors the
`run::gui` function to not depend on this `Error` at all. Instead, we
use `anyhow::Result` and probe for particular errors that we want to
special-case. This is a bit less type-safe because there is no source
code-level connection between the source site that emits an error and
the error handling code.

In the worst case, any regression here is "just" a slight degradation in
UX: We will show a generic error dialog instead of a tailored message.
This risk is deemed acceptable in exchange for an easier to understand
control flow.
2025-02-05 00:35:38 +00:00