Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Clearing Cloudflare cache #12

Open
MouseWithBeer opened this issue Jun 3, 2019 · 2 comments
Open

Clearing Cloudflare cache #12

MouseWithBeer opened this issue Jun 3, 2019 · 2 comments
Assignees
Labels
enhancement New feature or request

Comments

@MouseWithBeer
Copy link
Collaborator

An option to clear the Cloudflare cache (we all know the problems it caused) via their API to save 5 seconds of time and a couple of clicks to go to the website instead.

@MouseWithBeer MouseWithBeer added the enhancement New feature or request label Jun 3, 2019
@MouseWithBeer MouseWithBeer self-assigned this Jun 3, 2019
@insideone
Copy link
Owner

Do you want to do it by yourself or I can assign the issue?
 
The best way is to add a command to src/Command and call it in composer.json/scripts/up like doctrine:schema:update.

Since we don't need to clear cache in dev environment, command should do a dry run if API key isn't provided via .env.local
You can pass API key to command in such way: config/services.yaml:67

    App\Command\ClearCloudflareCacheCommand:
        calls:
            - method: setApiKey
              arguments:
                  $apiKey: '%env(CLOUDFLARE_API_KEY)%'

@MouseWithBeer
Copy link
Collaborator Author

@insideone You know more than me about it so you can do it if you wish. Just shoot me a message on Steam if you want and I will give you all the info you need.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants