cmd/web: rename to tclipd
This commit is contained in:
parent
4085af8a6f
commit
90fa48d541
2
.github/workflows/nix.yaml
vendored
2
.github/workflows/nix.yaml
vendored
|
@ -17,7 +17,7 @@ jobs:
|
||||||
github_access_token: ${{ secrets.GITHUB_TOKEN }}
|
github_access_token: ${{ secrets.GITHUB_TOKEN }}
|
||||||
- name: "Basic CLI and web build"
|
- name: "Basic CLI and web build"
|
||||||
run: |
|
run: |
|
||||||
nix build .#tclip .#web
|
nix build .#tclip .#tclipd
|
||||||
- name: "Docker image build"
|
- name: "Docker image build"
|
||||||
run: |
|
run: |
|
||||||
nix build .#docker
|
nix build .#docker
|
||||||
|
|
14
flake.nix
14
flake.nix
|
@ -35,18 +35,18 @@
|
||||||
version = builtins.substring 0 8 self.lastModifiedDate;
|
version = builtins.substring 0 8 self.lastModifiedDate;
|
||||||
in {
|
in {
|
||||||
packages = rec {
|
packages = rec {
|
||||||
web = pkgs.buildGoApplication {
|
tclipd = pkgs.buildGoApplication {
|
||||||
pname = "tclip-web";
|
pname = "tclipd";
|
||||||
version = "0.1.0-${version}";
|
version = "0.1.0-${version}";
|
||||||
go = pkgs.go_1_21;
|
go = pkgs.go_1_21;
|
||||||
src = ./.;
|
src = ./.;
|
||||||
subPackages = "cmd/web";
|
subPackages = "cmd/tclipd";
|
||||||
modules = ./gomod2nix.toml;
|
modules = ./gomod2nix.toml;
|
||||||
};
|
};
|
||||||
|
|
||||||
tclip = pkgs.buildGoApplication {
|
tclip = pkgs.buildGoApplication {
|
||||||
pname = "tclip";
|
pname = "tclip";
|
||||||
inherit (web) src version modules;
|
inherit (tclipd) src version modules;
|
||||||
subPackages = "cmd/tclip";
|
subPackages = "cmd/tclip";
|
||||||
go = pkgs.go_1_21;
|
go = pkgs.go_1_21;
|
||||||
|
|
||||||
|
@ -56,7 +56,7 @@
|
||||||
docker = pkgs.dockerTools.buildLayeredImage {
|
docker = pkgs.dockerTools.buildLayeredImage {
|
||||||
name = "ghcr.io/tailscale-dev/tclip";
|
name = "ghcr.io/tailscale-dev/tclip";
|
||||||
tag = "latest";
|
tag = "latest";
|
||||||
config.Cmd = [ "${web}/bin/web" ];
|
config.Cmd = [ "${tclipd}/bin/tclipd" ];
|
||||||
contents = [ pkgs.cacert ];
|
contents = [ pkgs.cacert ];
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -64,10 +64,10 @@
|
||||||
web-service = pkgs.substituteAll {
|
web-service = pkgs.substituteAll {
|
||||||
name = "tclip.service";
|
name = "tclip.service";
|
||||||
src = ./run/portable-service/tclip.service.in;
|
src = ./run/portable-service/tclip.service.in;
|
||||||
inherit web;
|
inherit tclipd;
|
||||||
};
|
};
|
||||||
in pkgs.portableService {
|
in pkgs.portableService {
|
||||||
inherit (web) version;
|
inherit (tclipd) version;
|
||||||
pname = "tclip";
|
pname = "tclip";
|
||||||
description = "The tclip service";
|
description = "The tclip service";
|
||||||
homepage = "https://github.com/tailscale-dev/tclip";
|
homepage = "https://github.com/tailscale-dev/tclip";
|
||||||
|
|
|
@ -6,7 +6,7 @@ Documentation=https://github.com/tailscale-dev/tclip
|
||||||
DynamicUser=yes
|
DynamicUser=yes
|
||||||
StateDirectory=tclip
|
StateDirectory=tclip
|
||||||
Environment=DATA_DIR=/var/lib/private/tclip/data
|
Environment=DATA_DIR=/var/lib/private/tclip/data
|
||||||
ExecStart=@web@/bin/web
|
ExecStart=@tclipd@/bin/tclipd
|
||||||
Restart=always
|
Restart=always
|
||||||
RestartSec=30s
|
RestartSec=30s
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue