Skip to content

Script to automatically clear the Akamai CDN http cache based on github repo tags.

Notifications You must be signed in to change notification settings

lilmuckers/akamai-cache-clear

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 

Repository files navigation

Akamai Cache Clearer

This is a PHP script that uses the GitHub API and the Akamai CCUAPI to clear items from the HTTP cache for the Akamai CDN network.

You provide it with the tags that describe the old release tag and the new release tag, it logs into the GitHub API to get the differences, and clears out the items that match a set of paths provided in the configuration.

Configuration

You will need a GitHub oAuth access token (how to get one of these isn't covered here), the owner and repo name of the repo (for example for this repo the owner is me, lilmuckers and the repo is akamai-cache-clear.

You will need a login for the Akamai Luna control panel, with permissions to use the Content Control Utility to clear items from the cache.

Options are specified in a key/value way, as below. For all options; see the akamai documentation.

Paths have a key of the base path in your repo, and a value of the equivilent Akamai base path.

[github]
access_token = 
owner = 
repo = 

[akamai]
username = 
password = 
options[action] = remove
options[type] = arl
paths[images] = http://a9.g.akamai.net/7/2/3/4/www.example.com/images/

Usage

This script is run with the following command:

 $ php akamai.php --old=v1.1.2 --new=v1.1.3

About

Script to automatically clear the Akamai CDN http cache based on github repo tags.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages