<p>I am in the middle of no where. Following this tutorial <a href="https://cloud.google.com/container-engine/docs/tutorials/persistent-disk" rel="nofollow noreferrer">https://cloud.google.com/container-engine/docs/tutorials/persistent-disk</a></p>

<p>I deployed wordpress to google container engine. Now i have no idea how to access wordpress files on this Persistent Disks either with ftp or sftp. I can access project files with sftp on filezilla but can't find wordpress core files in it. Is there any way i can access these wordpress files?</p>

<p>The persistent disk containing the wordpress files are attached to the wordpress pod. This disk is mounted on /var/www/html folder under the wordpress pod. You can access these files by connecting to the wordpress pod. First get the name of the running pod by executing the following command,</p>

<pre><code> kubectl get pods
</code></pre>

<p>Now use the name of the wordpress pod in the following command. This runs a remote shell on the wordpress pod,</p>

<pre><code>kubectl exec -it &lt;POD_NAME&gt; sh
</code></pre>

<p>In the shell, run the ls command to see the list of wordpress files,</p>

<pre><code># ls
</code></pre>

<p>This will list the wordpress files. If you want to edit these files, you need to install vim or nano.</p>

<pre><code># apt-get update
# apt-get install vim
# apt-get install nano
# vi wp-config.php
</code></pre>

<p>Note that the vim/nano will be removed if the wordpress pod is restarted. If you really want them inside your pod, you will need to create a custom container.</p>
