mirror of
https://github.com/larstvei/nix-config.git
synced 2026-02-06 10:30:12 +00:00
Working email setup
This commit is contained in:
parent
b7c7821e70
commit
753513fd64
@ -13,10 +13,12 @@
|
|||||||
];
|
];
|
||||||
|
|
||||||
services.fprintd.enable = true;
|
services.fprintd.enable = true;
|
||||||
|
services.gnome.gnome-keyring.enable = true;
|
||||||
security.pam.services = {
|
security.pam.services = {
|
||||||
login.fprintAuth = true;
|
login.fprintAuth = true;
|
||||||
sudo.fprintAuth = true;
|
sudo.fprintAuth = true;
|
||||||
hyprlock.fprintAuth = true;
|
hyprlock.fprintAuth = true;
|
||||||
|
login.enableGnomeKeyring = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
systemd.services.disable-thinkpad-leds = {
|
systemd.services.disable-thinkpad-leds = {
|
||||||
|
|||||||
@ -1,6 +1,35 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, ... }:
|
||||||
{
|
{
|
||||||
home.packages = [ pkgs.oama ];
|
home.packages = [
|
||||||
|
pkgs.oama
|
||||||
|
];
|
||||||
|
|
||||||
|
services.gnome-keyring = {
|
||||||
|
enable = true;
|
||||||
|
components = [ "secrets" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
# Use Thunderbird's Client ID
|
||||||
|
xdg.configFile."oama/config.yaml".text = builtins.toJSON {
|
||||||
|
encryption = {
|
||||||
|
tag = "KEYRING";
|
||||||
|
};
|
||||||
|
services = {
|
||||||
|
microsoft = {
|
||||||
|
client_id = "9e5f94bc-e8a4-4e73-b8be-63364c29d753";
|
||||||
|
redirect_uri = "http://localhost:8080";
|
||||||
|
scopes = [
|
||||||
|
"offline_access"
|
||||||
|
"https://outlook.office.com/IMAP.AccessAsUser.All"
|
||||||
|
"https://outlook.office.com/SMTP.Send"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
home.sessionVariables = {
|
||||||
|
SASL_PATH = "${pkgs.cyrus-sasl-xoauth2}/lib/sasl2:${pkgs.cyrus_sasl}/lib/sasl2";
|
||||||
|
};
|
||||||
|
|
||||||
programs = {
|
programs = {
|
||||||
mu.enable = true;
|
mu.enable = true;
|
||||||
@ -16,16 +45,36 @@
|
|||||||
realName = "Lars Tveito";
|
realName = "Lars Tveito";
|
||||||
|
|
||||||
imap.host = "outlook.office365.com";
|
imap.host = "outlook.office365.com";
|
||||||
smtp.host = "smtp.office365.com";
|
|
||||||
|
smtp = {
|
||||||
|
host = "smtp.office365.com";
|
||||||
|
port = 587;
|
||||||
|
tls = {
|
||||||
|
enable = true;
|
||||||
|
useStartTls = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
mbsync = {
|
mbsync = {
|
||||||
enable = true;
|
enable = true;
|
||||||
create = "maildir";
|
create = "maildir";
|
||||||
|
expunge = "both";
|
||||||
|
extraConfig.account = {
|
||||||
|
AuthMechs = "XOAUTH2";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
passwordCommand = "oama access larstvei@ifi.uio.no";
|
msmtp = {
|
||||||
|
enable = true;
|
||||||
|
extraConfig = {
|
||||||
|
auth = "xoauth2";
|
||||||
|
user = "larstvei@uio.no";
|
||||||
|
from = "larstvei@ifi.uio.no";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
passwordCommand = "${pkgs.oama}/bin/oama access larstvei@ifi.uio.no";
|
||||||
|
|
||||||
msmtp.enable = true;
|
|
||||||
mu.enable = true;
|
mu.enable = true;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user