<p>I have configured the cluster for guestbook-go application by using EKS <a href="https://github.com/kubernetes/examples/tree/master/guestbook-go" rel="nofollow noreferrer">https://github.com/kubernetes/examples/tree/master/guestbook-go</a></p>

<p>and followed the official tutorial
<a href="https://docs.aws.amazon.com/eks/latest/userguide/getting-started.html" rel="nofollow noreferrer">https://docs.aws.amazon.com/eks/latest/userguide/getting-started.html</a></p>

<p>Let's say I want to amend <code>public/index.html</code> file. In a Docker file I can see that the file is copied to the container:</p>

<p><code>COPY ./public/index.html public/index.html</code></p>

<p>In the <code>guestbook-controller.json</code> I can see the image that it was used:
<code>"image":"k8s.gcr.io/guestbook:v3",</code></p>

<p>What is the correct way to modify <code>index.html</code> and deploy this new version?
Do I need to rebuild this image? Then where is the right place to upload it and how to deploy it with kubernetes tools on AWS?</p>

<p>Many thanks, as a newcomer to Kubernetes, looking for good steps to learn it</p>

laimison
<p>Here are the steps at a high level to setup a fresh application with new image.</p>
<blockquote>
<ol>
<li><p>Do a git clone of the repository.</p>
</li>
<li><p>Modify the public/index.html locally.</p>
</li>
<li><p>Do a Docker build using <code>docker build ....</code></p>
</li>
<li><p>Push the image to a registry (<a href="https://hub.docker.com/" rel="nofollow noreferrer">https://hub.docker.com/</a> or <a href="https://cloud.google.com/container-registry/" rel="nofollow noreferrer">https://cloud.google.com/container-registry/</a> or some where else). The command depends on the registry. Also, make sure that the image is public.</p>
</li>
<li><p>Update the image appropriately in guestbook-controller.json.</p>
</li>
<li><p>Follow the steps as mentioned in the README.md.</p>
</li>
</ol>
</blockquote>
<p>If you want to update the image in an existing K8S application already running, then a rolling-update has to be done as mentioned <a href="https://kubernetes.io/docs/tasks/run-application/rolling-update-replication-controller/#updating-the-container-image" rel="nofollow noreferrer">here</a>.</p>
<p>FYI ..... Without creating the image, the index.html can also be modified by copying the new index.html to all the running Pods as mentioned <a href="https://stackoverflow.com/questions/52677618/how-to-use-kubectl-cp-to-copy-files-automatically-from-a-local-system-to-kuberne/52678961#52678961">here</a>.</p>
<p>FYI ..... the example uses <a href="https://kubernetes.io/docs/concepts/workloads/controllers/replicationcontroller/" rel="nofollow noreferrer">ReplicationController</a> which is outdated (mentioned in guestbook-controller.json), a <a href="https://kubernetes.io/docs/concepts/workloads/controllers/deployment/" rel="nofollow noreferrer">Deployment</a> is the recommended way.</p>
