Commit graph

15 commits

Author SHA1 Message Date
Sandro Jäckel
692f94d84a Fix lint errors, disable gosec
gosec only found int to uint downcasts which are unavoidable as sadly
the go API usually uses int instead of uint in places.
2025-09-09 22:31:41 +02:00
Darren Dormer
b33837ae3c Fix symlink ownership change on Darwin systems. 2025-03-17 11:57:40 +01:00
Ian
d2bd7f433b Implement darwin module for sops-nix 2024-11-16 09:09:49 +00:00
Janne Heß
b549832718 darwin: Mount hfs+ case-sensitive
sops-nix assumes this is the case since it's the default on linux
2024-05-22 17:51:40 +00:00
Kaede Akino
0cd7cac744 sops-install-secrets: add mount options for darwin 2024-05-22 17:51:40 +00:00
Jörg Thalheim
6b259336bd
Lint fixes (#539)
* fix various additional linter errors

* extend golangci checks
2024-04-18 16:19:26 +02:00
Jörg Thalheim
c59da7ac29 reformat with gofumpt 2023-11-03 14:49:21 +01:00
Shyim
1b7b3a32d6 Update pkgs/sops-install-secrets/darwin.go
Co-authored-by: Leo Pang <34628052+allthatjazzleo@users.noreply.github.com>
2023-08-22 19:24:38 +01:00
Shyim
fce0c8ce93 fix: add missing argument for MountSecretFs on darwin 2023-08-22 19:24:38 +01:00
Roman Gonzalez
2ff6973350 fix(darwin): RuntimeDir trailing slash
In later versions of macOS (e.g. Ventura), the command used to get a
runtime directory (e.g. `getconf DARWIN_USER_TEMP_DIR`) returns a
trailing slash.

When using a configuration like:

```
sops.defaultSecretsMountPoint = "%r/secrets.d";
```

The final path is going to contain a double slash in the suffix of the
path, an example:

```
/var/<random>/<hash>//secrets.d
```

This commit ensures that the runtime dir will get the trailing '/'
character removed.
2023-06-22 01:49:29 +00:00
Roman Gonzalez
4ce3cc3428 fix(darwin): use chown only on non user mode
On the latest version of macOS (Ventura 13.4 as of this date), this
change ownership will always fail with the error:

> Failed to mount filesystem for secrets: Cannot change owner/group of '.../secrets.d' to 0/0: chown .../secrets.d: operation not permitted
2023-06-22 01:49:29 +00:00
Pogobanane
466d039190 darwin/home-manager: %r dir 2023-02-02 12:07:00 +01:00
Pogobanane
98834d958b darwin: impl MountSecretFs 2023-02-02 12:07:00 +01:00
Pogobanane
e6ccc740d8 darwin: impl SecureSymlinkChown 2023-02-02 12:07:00 +01:00
Pogobanane
4f3d45c058 go files for darwin
fixup
2023-02-02 11:38:33 +01:00