Skip to content
Branch: master
Find file History
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
..
Failed to load latest commit information.
Dockerfile
README.md
nginx-config.yml
nginx-service.yml
skaffold.yaml
watch-nginx.sh

README.md

Auto-Reload: Inotifywait example

Purpose: use inotifywait to watch for ConfigMap changes and to send signal to Nginx if necessary.

To simply the demo steps, use Skaffold to bootstrap the whole stuff.

.
├── Dockerfile
├── nginx-config.yml
├── nginx-service.yml
├── skaffold.yaml
└── watch-nginx.sh

0 directories, 5 files

Usage

  1. Create a inotify-example namespace for this test:

    % kubectl create ns inotify-example
    
  2. Use Skaffold to load configmap content (nginx-config) and bring up nginx app (service/nginx) in the inotify-example namespace:

    % skaffold dev  -n inotify-example
    
  3. Edit the ConfigMap content, eithor by:

    % kubectl edit configmap nginx-config  -n inotify-example
    

    or by:

    % vi nginx-config.yml
    

Demo

You can see the demo at:

asciicast

You can’t perform that action at this time.