# SPDX-FileCopyrightText: 2023 Richard Brežák # # SPDX-License-Identifier: LGPL-3.0-or-later { pkgs, inputs', ... }: let configuration = inputs'.nixng.nglib.makeSystem { system = pkgs.system; name = "monitor"; nixpkgs = inputs'.nixpkgs-stable; config = {pkgs, ...}: { dumb-init.enable = true; dumb-init.type.services = {}; init.services.network = { enabled = true; script = pkgs.writeShellScript "network-start" '' ip addr add "172.20.69.5/31" dev "eth0" ip link set "eth0" up ip route add "172.20.69.4/31" dev "eth0" ip route add default via "172.20.69.4" cat > /etc/hosts <> 'log') as log, # (data ->> 'namespace') as namespace, # (data ->> 'level')::synapse_log_level as level, # to_timestamp((data ->> 'time')::float) as time, # (data ->> 'request') as request, # (data ->> 'ip_address')::inet as ip_address, # (data ->> 'site_tag') as site_tag, # (data ->> 'requester') as requester, # (data ->> 'authenticated_entity') as authenticated_entity, # (data ->> 'method')::http_method as method, # (data ->> 'url') as url, # (data ->> 'protocol') as protocol, # (data ->> 'user_agent') as user_agent, # (data ->> 'server_name') as server_name # FROM jsonb_array_elements('[ # ]'::jsonb) AS item(data);