{"id":21719863,"url":"https://github.com/actcoding/smtp-cli","last_synced_at":"2025-06-26T23:04:25.653Z","repository":{"id":263574987,"uuid":"864642798","full_name":"actcoding/smtp-cli","owner":"actcoding","description":"📨 Send emails right from your terminal.","archived":false,"fork":false,"pushed_at":"2024-09-29T19:50:01.000Z","size":10,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-03-14T22:54:46.840Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/actcoding.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-09-28T19:05:22.000Z","updated_at":"2024-09-29T19:50:04.000Z","dependencies_parsed_at":"2024-11-19T09:56:41.153Z","dependency_job_id":"04c7bfaa-45dc-4190-8eda-581283c058d8","html_url":"https://github.com/actcoding/smtp-cli","commit_stats":null,"previous_names":["actcoding/smtp-cli"],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/actcoding%2Fsmtp-cli","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/actcoding%2Fsmtp-cli/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/actcoding%2Fsmtp-cli/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/actcoding%2Fsmtp-cli/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/actcoding","download_url":"https://codeload.github.com/actcoding/smtp-cli/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":244688409,"owners_count":20493808,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-26T01:42:43.787Z","updated_at":"2025-03-20T20:52:28.569Z","avatar_url":"https://github.com/actcoding.png","language":"Go","readme":"# smtp-cli\n\n\u003e 📨 Send emails right from your terminal.\n\nWe use this tool to send an informational email whenever someone logs in to one of our servers.\nIntended usage is via [pam_exec(8)](https://linux.die.net/man/8/pam_exec).\n\nEmails are sent directly via SMTP. The config is read from a json file, see [Config](#config).\n\nThe message body is produced via go templates, see [Templates](#templates).\n\n## Installation\n\nDownload an archive (`.tar.gz`) from the latest release and run the `install.sh` script.\n\n## Usage\n\nAdd the following snippet to `/etc/pam.d/sshd`:\n\n```\nsession    required     pam_exec.so /usr/local/bin/smtp-cli -config /usr/local/etc/smtp-cli/config.json -template /usr/local/etc/smtp-cli/template.gotmpl\n```\n\n## Config\n\n```json\n{\n    \"host\":  \"mail.example.org\",\n\t\"port\":  465,\n\t\"username\":  \"no-reply@example.org\",\n\t\"password\":  \"\",\n\t\"from\":  \"monitor \u003cno-reply@example.org\u003e\",\n\t\"to\":  [\n\t\t\"info \u003cinfo@example.org\u003e\"\n\t],\n\t\"subject\": \"New login to the server\"\n}\n```\n\n## Templates\n\nThe following variables are made available to the go template:\n\n| Variable | Type |\n| --- | --- |\n| Host       | string |\n| User       | string |\n| RemoteUser | string |\n| RemoteHost | string |\n| Tty        | string |\n| Timestamp  | time.Time |\n\n## License\n\n[MIT](LICENSE)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Factcoding%2Fsmtp-cli","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Factcoding%2Fsmtp-cli","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Factcoding%2Fsmtp-cli/lists"}