Add LDAP Login to PHP Webpage
- Written by: Andrew Wellington
- Category: Synology
- Hits: 392
So you have an LDAP server and you'd like to add authentication to a PHP based website. Well you have came to the right place! I started hosting my own mail server (Don't ask) and used LDAP for authentication so it made sense to create a website with LDAP and webmail/roundcube as well. I will go over step by step instructions on how to get this set up including code snippets. You will need to modify the code to fit your environment but my guide should get you most of the way there!
Schedule a PowerShell Script with SQL Server Agent
- Written by: Andrew Wellington
- Category: Powershell
- Hits: 284
There are many ways to schedule a PowerShell script to run within windows. The most common way is to use task scheduler however if your PowerShell script is invoking SQL commands, I find it is best to use the SQL server agent to schedule the job. This keeps all of your database based scripts in one place. This is very important when it comes time to upgrade or migrate the server. I will go over how to schedule the script in SQL Server 2016 as well as add email notifications and output to a text file.
Setup Postfix as a Send-Only External SMTP Relay
- Written by: Andrew Wellington
- Category: Linux
- Hits: 660
Self-hosting a mail server can be a great learning experience. I recently set up an email server using Docker Mail-Server and I ran into an issue with outgoing mail where my public IP was on a policy blocklist. This caused almost all of my outgoing emails to be blocked. If you are faced with this problem, there are two directions you can go. You can sign up for an SMTP service, some are even free up to a certain number of emails, or you can run a postfix relay in a VPS. I like to have control of the underlying infrastructure, so I went with the latter. This guide will walk you through how to configure the Postfix relay server on the VPS so that it only accepts mail from your mail server's IP or from a server with a certificate that matches your mail server's hostname.