Repository navigation
4.2.1 lifts the 4.1.1 pause on via vault, introduces Viaalink Apps in alpha (with the first ten public apps and optional vault-backed app secrets), adds WireGuard device traffic inspection (via inspect start --device) plus MySQL, MariaDB and Redis decoders to the network inspector, ships via's own Caddy 2.11.7 build (with caddy-security, caddy-l4 and DNS-01 providers) in every release archive, fixes Caddy restart recovery and package routing, and patches a critical cross-spawn advisory.
Install or update
curl -fsSL https://raw.githubusercontent.com/viaalink/cli/main/install.sh | bashWindows (PowerShell): irm https://raw.githubusercontent.com/viaalink/cli/main/install.ps1 | iex · Already on 4.x: via update · Coming from 3.x: run the installer again.
Security
cross-spawn7.1.2 (was 7.0.6). Resolves GHSA-ghv9-86vm-4v8m (critical, command injection on Windows when spawning batch files) in the shipped dependency tree.
Added
via inspect start --deviceinspects a phone's or computer's own traffic.
It prints a WireGuard config and QR code to import on the device; all of its
TCP and UDP traffic then goes through this machine. Only that config's key
connects, and the listener binds to one address of this machine. TLS is not
opened, so no certificate goes on the device; each flow is logged with its
host, TLS version and whether its payload is readable. Each start is a run
with its own flow log and a control canary (--canary).via inspect stop --device --forgetalso removes the keys.- An app package can declare its network services in its own
via.yaml, with
the fields of a project'svia.yaml(network.services.<id>:dial,
host,public,subdomain,env,priority,rawRoutes, ...), in
place of anet.manifest.yaml.via net apply,via env initand
via config validateread it for every folder under the packages
directory that has anapp.yaml. A published HTTP service is reached
through the proxy without naming the proxy's port, and the project's
ENV_PREFIXgoes in front of the service id. Anet.manifest.yamlkeeps
working; a package with both files is refused with a message that names
them, and a field an app may not set (login, modes) is an error that says
to set it in the project'svia.yaml. - Three more fields on a
via.yamlservice, which until now only a
net.manifest.yamlcould set:responseHeaders(response headers the
proxy sets on that service's answers, for example
responseHeaders: { "Cache-Control": ["no-store"] }),authPolicy(the
login policy the proxy asks for in front of the service) and
authBypassPaths(paths that skip that policy, such as the service's own
sign-in callbacks). via config validatewarns when a service hassecuritySensitive: trueand
basic_auth: { enabled: false }. A securitySensitive service always keeps a
login, so thatenabled: falsedid nothing, and the file passed validation.
To publish such a service without a login (an app with its own sign-in),
removesecuritySensitive: true.- Viaalink Apps, alpha: the first ten apps are public. The registry
viaalink/appsholds Authentik, Gitea, Mattermost, n8n,
Open WebUI, Redmine, Apache Superset, Vaultwarden, Wiki.js and Zammad. Add it once with
via app registry add viaalink https://github.com/viaalink/apps; then, in a project folder
(via init),via app install <id>,via app start <id>andvia app setup <id>give a
running app with its first administrator made. With Authentik in the same project the other
apps connect their sign-in to it themselves. No registry is built in;via app listand
via app registry listnow name this command while none is added. - The vault is back, and apps can use it (optional). The
via vaultcommands load again
withoutVIA_ENABLE_VAULT=1; the pause of 4.1.1 is lifted.via app vault <id>stores an
installed app's generated secrets in the vault and leaves their addresses in.env
(KEY=via://<project>/<app>/KEY);via app startandvia app setuphand the app the
values.project.apps.vault: trueinvia.yamldoes this for every app at install. An
app file can name more secret keys withsecrets:. When an app's secrets are in.envas
plain text,via app installandvia app startsay so in one line; nothing is moved
unless you ask. prepare:steps in an app file. They run on everyvia app start <id>, before the
app's containers exist, for settings an app only reads when it starts (a sign-in client,
a repaired.envvalue). What a step writes to.envreaches the containers of that same
start, and the app's data folders and files are in place before a step runs. A failing
step stops the start.via app installandvia app infoshow them as
"Steps before every start";--onlystarts part of an app without them.via app setuphands each step the app's own folder asVIA_APP_DIRand its
data directory asVIA_APP_DATA_DIR, so an app can ship a setup script and
call it wherever the app is installed.project.apps.compose_projectandproject.apps.networkinvia.yaml:
a project can name the one Docker Compose project and the network its apps
run in, so a plainvia app statussees the same containers as a script
that setsVIA_APPS_COMPOSE_PROJECT/VIA_APPS_NETWORK(which still win).via app start <id> --only <service>[,<service>]starts only the named
services of an app (and what they depend on), for example its database
before a restore. It reports those containers only, and refuses a name that
is not one of the app's services.inspect: trueon a TCP service now shows MySQL, MariaDB and Redis traffic
decoded in the network inspector, next to Postgres: the inspector loads the
mysqlwire and rediswire decoders as well as pgwire. Each one recognises its
own protocol from the bytes, so one inspector serves every database. Logins
(a MySQL password, a RedisAUTH) are kept out of the stored flows, and
decoded queries and rows stay out of the inspector's log file. An inspector
that was started with the Postgres decoder alone is restarted on the next
via net apply.via app: install and run apps from an app registry. A registry is a git
repository or a directory with one folder per app (apps/<id>/app.yaml
plus its Docker Compose file); add one with
via app registry add <name> <git-url|directory>. No registry is built in.
via app list,via app search <text>andvia app info <id>show what
there is;via app install <id>shows the images, ports, volumes and setup
commands of the app and asks before it copies anything. The app lands in the
project'spackages/<id>/folder, its settings are added to.env, and
apps.lock.yamlrecords the registry, the commit and a hash of the package.
via app start|stop|status|setup|uninstall <id>run it; uninstalling keeps
the app's data volumes. An app with anet.manifest.yamlgets its address
fromvia net apply, like any other package of the project. A package the
project already has inpackages/<id>/is an app as soon as it has an
app.yaml: it starts and stops with the same commands and is never
uninstalled. An app's Compose file getsVIA_APP_DATA_DIR(its own data
folder in the project's workspace) andVIA_APPS_NETWORK(the Docker network
apps share,via-appsunless the project's.envnames another). Each app
runs in its own Docker Compose project named<project>-<app>, so two
projects on one machine can run the same app without sharing containers or
volumes. A one-off
container that ends without an error (migrations, first-time init) counts as
done, not as a failed start; a container that ends with an error and is
restarted by Docker fails the start, andvia app statusshows how often
each container was restarted.via app info <id>also describes an app the
project already has, with no registry added. An app can
name files it needs in its data folder before the first start (files:in
app.yaml, a copy of a package file or an empty file); a file that exists is
never replaced. A project
that already runs its packages in one Docker Compose project keeps doing so
by settingVIA_APPS_COMPOSE_PROJECTin.env;via app startand
via app statusthen count and show only the app's own containers, not
those of the other apps in that Compose project. This first
version does not check signatures and has noupdateyet.
Fixed
- Releases and nightlies ship via's own Caddy build again (Caddy 2.11.7 with
caddy-security, caddy-l4 and the DNS-01 providers, from
viaalink/caddy-dns-builds), asviaitself downloads it. They carried
upstream's plain Caddy 2.11.2, socaddy-securityroutes, Layer 4
(TCP inspect) routes and DNS-01 certificates failed on a fresh install.
Every archive is checked against the checksum pinned in the CLI, and a
build without these modules is refused, never replaced by plain Caddy. - The network inspector's page on the published hub address
(https://hub-…/asde/inspect/) shows traffic live again: its WebSocket was
refused (403, "connection lost") because the relay route sent mitmweb the
service's own address as Host, so every browser Origin looked foreign. The
inspector's route now keeps the browser's Host (new manifest field
caddy.keepHost); mitmweb's check still refuses other origins. via inspect stopno longer takes inspected databases down: a TCP
service's local address (Local TCPinvia net urls) now goes straight to
the database while the inspector is stopped, and says so per service.
Before, its connections went to the stopped inspector and failed or hung.
via net applyputs the inspector back in front.project.tunnel.domainalso holds for a project's packages. Apackages/<name>/net.manifest.yaml
without atunnel.domainof its own was published on the relay's main domain, while the services
invia.yamlwent to the project's domain. A package now followsproject.tunnel.server/
.domain(then the machine's preference) like every other service, and its address in.env
is predicted the same way.- A package's address in
.envis the one it is published at.${{ macro.exposedOrigin() }}
in anet.manifest.yamlenv:block wrote the manifest id on the relay's main domain
(https://qemu-redmine.relay.example), whilevia net applypublished the manifest's own
tunnel.subdomainon itstunnel.domain, with the ending the relay gives this device's names
(https://redmine-nico.office.example). The app was told an address nothing answers on. The
macro now uses the manifest's name and domain and the relay's naming, as publishing does. via net startstarts a service declared invia.yaml. A service withprocess.cmd
failed with "No lifecycle" until avia net applyhad registered it; it now starts from
via.yamlright away. And it no longer says "already running" when the service is shown
online only because its public address answers: it now checks whether something answers on
the service's owndialaddress, and says what it found.- A free port is free for UDP too.
getRandomPort()and every other port the CLI picks
checked TCP only, so a port another program held for UDP could be handed to an app that
publishes the same number for both; its start then failed with "address already in use". - After a reboot, publishing no longer fails on a Caddy that is only recorded as running.
via caddy startandvia net apply --caddytrusted the recorded process: when that
process id belonged to something else after a restart of the machine, or the recorded
Caddy did not respond, they said "Caddy already running" and then stopped with
ERR_CADDY_RELOAD, so nothing was published until someone ran the command again. A
recorded Caddy now counts as running only when its admin API answers; otherwise a new one
is started. A process that is not proven to be Caddy is never stopped. - A shared project keeps its published state when another user runs the CLI in it. On a
machine where several users work in one project folder, aviacommand run by another
user rewrote the project's network registry from that user's own relays and proxy: every
service then showed as "not published" although it still was. A registry kept by another
user is now read and never rewritten; one warning says so and how to take it over. The
administrator is not held back. - The installer keeps the old relay client (
asd-tunnel) while a systemd unit
still starts it by its path, and names those units. It used to remove the file
as soon asviaalink-relayran, so such a unit failed at the next boot. via relay addfor a relay that is already registered (for example to add
a host-key fingerprint) no longer drops what the relay reported about
itself: its hostname shape, ports and version stay, only the domains the
new probe learned change.features.hub_visibility: falsenow switches the hub off for
via net applyas documented: no dashboard files are written and the web
terminal is not started. Before, only the hub's tunnel was left out.via config validatechecks a packagenet.manifest.yamlafter its${{ ... }}templates are filled in, the wayvia netloads it. Before, every manifest with a templatedidwas reported as an error. A real error now names the field (caddy.publishPreferred: ...) instead of showing cut-off JSON.project.package_manifests_dirinvia.yamlnow works. It was documented
as the way to keep a project's packages in another folder thanpackages/,
but the setting was dropped when the file was read, so only the
ASD_PACKAGE_MANIFESTS_DIRenvironment variable had an effect.