Skip to content

RedHatInsights/frontend-cache-bust

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

24 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Frontend Cache Buster

This was inspired by https://github.com/akamai/akamai-docker/blob/master/dockerfiles/purge.Dockerfile but modified to run in a Red Hat environment

Example usage:

$ podman build -f cacheBuster.Dockerfile -t akamai-purge .
$ podman run -it -v ~/.edgerc:/opt/app-root/edgerc:z -it akamai-purge invalidate https://somewhere.com/some/cached/file https://somewhere.com/some/other/cached/file

Notes:

  • you have to have your akamai creds in a file that you mount to /opt/app-root/edgerc
  • I added the -z in the mount to prevent selinux weirdness but YMMV
  • The akamai creds file format is SUPER finicky and needs to be exactly like this but with the hash marks removed:
[default]
client_secret = FOOFOOFOOFOOFOOFOOFOOFOOFOOFOOF
host = asomecrazyhostname.com
access_token = BARBARBARBARBARBARBARBARBARB
client_token = DEADBEEFDEADBEEFDEADBEEF
[ccu]
client_secret = FOOFOOFOOFOOFOOFOOFOOFOOFOOFOOF
host = asomecrazyhostname.com
access_token = BARBARBARBARBARBARBARBARBARB
client_token = DEADBEEFDEADBEEFDEADBEEF

You can set up creds via directions in this article https://techdocs.akamai.com/developer/docs/set-up-authentication-credentials

About

Image for performing frontnend cache busting

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •