Compare commits

...

2 Commits

Author SHA1 Message Date
Ciapa 6d826ee4d2 Add broken workaround to fix nixos deployment
ci/woodpecker/push/deploy Pipeline failed Details
2024-05-20 16:08:27 +02:00
Ciapa 6f92c589c3 Make woodpecker config work again 2024-05-20 16:08:10 +02:00
2 changed files with 10 additions and 22 deletions

View File

@ -7,34 +7,25 @@ variables: &nix-config
NIXPKGS_ALLOW_INSECURE: "1" NIXPKGS_ALLOW_INSECURE: "1"
steps: steps:
- name: Configure Nix Channels - name: Check Flake
image: bash image: nixos/nix:latest
pull: true
commands: commands:
- nix-channel --add https://nixos.org/channels/nixos-$${NIXOS_VERSION} nixos - nix-channel --add https://nixos.org/channels/nixos-$${NIXOS_VERSION} nixos
- nix-channel --update - nix-channel --update
environment:
*nix-config
when:
- evaluate: 'CI_PIPELINE_EVENT != "cron" && CI_PIPELINE_EVENT != "schedule"'
- name: Check Flake
image: bash
commands:
- nix flake check - nix flake check
environment: environment:
*nix-config *nix-config
when: when:
- evaluate: 'CI_PIPELINE_EVENT != "cron" && CI_PIPELINE_EVENT != "schedule"' - evaluate: 'CI_PIPELINE_EVENT != "cron" && CI_PIPELINE_EVENT != "schedule"'
- name: Place SSH Key
image: bash
commands:
- echo $${SSH_PRIVATE_KEY}} > .privkey
- chmod 0600 .privkey
- name: Deploy - name: Deploy
image: bash image: nixos/nix:latest
pull: true
commands: commands:
- nix-env -iA nixos.openssh
- eval "$(ssh-agent -s)"
- echo $${SSH_PRIVATE_KEY}} | ssh-add -
- nix develop --command deploy - nix develop --command deploy
environment: environment:
*nix-config *nix-config

View File

@ -1,6 +1,6 @@
{ config, pkgs, lib, ... }: { config, pkgs, lib, ... }:
{ {
networking.firewall.allowedTCPPorts = [ ]; networking.firewall.allowedTCPPorts = [ 6080 ];
services.transfer-sh = { services.transfer-sh = {
enable = true; enable = true;
settings = { settings = {
@ -12,8 +12,5 @@
PURGE_DAYS = "90"; PURGE_DAYS = "90";
}; };
}; };
systemd.services.transfer-sh.serviceConfig.ReadWritePaths = lib.mkForce [ systemd.services.transfer-sh.serviceConfig.ReadWritePaths = lib.mkForce "/mnt/data/transfer-sh";
"/mnt/data/transfer-sh/temp"
"/mnt/data/transfer-sh/store"
];
} }