Skip to content

Instantly share code, notes, and snippets.

@Praseetha-KR

Praseetha-KR/user-data.yml

Last active May 14, 2020
Embed
What would you like to do?
Squid proxy cloud-init config
#cloud-config
package_update: true
packages:
- squid
- apache2-utils
write_files:
- path: /etc/squid/squid.conf
content: |
auth_param basic program /usr/lib/squid/basic_ncsa_auth /etc/squid/htpasswd
auth_param basic realm proxy
acl authenticated proxy_auth REQUIRED
http_access allow authenticated
http_port 0.0.0.0:3128
runcmd:
- htpasswd -b -c /etc/squid/htpasswd USERNAME PASSWORD
- systemctl enable squid
- systemctl restart squid
- ufw enable
- ufw allow ssh
- ufw allow 'Squid'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.