Posts Tagged: go

Caddy Server and WordPress (PHP-FPM)

Update: I added rewrite rules for WordPress permalinks to the Caddyfile. I also removed all unnecessary bits which are not needed anymore since Caddy now has built-in HTTPS support with Let’s Encrypt. Recently I discovered an amazing open source project: Caddy, a fully functional HTTP/2 webserver, written in Go. Caddy is a lightweight, general-purpose web server for… Read more »

Go: Interface (example)

An Interface in Go defines a behavior. Interfaces are defined with a number of methods that a type must implement. Once the methods are implemented, the type can be used wherever the interface type is needed. Let’s for example define a Phone interface: type Phone interface { Call() } We also define a Nokia type that… Read more »