X-Git-Url: https://feistymeow.org/gitweb/?a=blobdiff_plain;ds=inline;f=production%2Fsites%2Fcakelampvm.com%2Fdocs%2Fmanual%2Fcakelampvm_guide_v002.html;h=81ba2ece90304bef8c6a0e51b1e9db95460da0c8;hb=24ea8036c547ba2ce25b871c4f0e7c6bfd982ec7;hp=883179042f6431ac276a20a3cbaad29c29cfa8e7;hpb=e10ca9e18141b1fc3ba364b552e67d129d0649f2;p=feisty_meow.git
diff --git a/production/sites/cakelampvm.com/docs/manual/cakelampvm_guide_v002.html b/production/sites/cakelampvm.com/docs/manual/cakelampvm_guide_v002.html
index 88317904..81ba2ece 100644
--- a/production/sites/cakelampvm.com/docs/manual/cakelampvm_guide_v002.html
+++ b/production/sites/cakelampvm.com/docs/manual/cakelampvm_guide_v002.html
@@ -11,7 +11,7 @@
Koeritz
feisty meow® concerns ltd.
The cakelampvm project provides a Virtualbox VM that acts as an "internet in a bottle", serving up your web sites securely and only to your local host. The virtual machine provides DNS services (Saco Design of Winterport, Maine.
-Commands preceded by an octothorpe ('#') below are intended to be typed - into a bash shell running on the cakelampvm virtual machine. The - bash shell can be obtained either by logging into the VM through ssh or by - logging in directly to the Virtualbox VM console. You may find the - ssh session more convenient, because copy & paste features work as - expected.
+Commands in fixed-width bold below are intended to be typed into a bash + shell running on the cakelampvm virtual machine. The bash shell can + be obtained either by logging into the VM through ssh or by logging in + directly to the Virtualbox VM console. You may find the ssh session + more convenient, because copy & paste features work as expected.
Commands preceded by a greater-than symbol ('>') are intended to be run on the Host PC in a Windows command prompt (or in a bash prompt running on the Host PC).
@@ -99,7 +98,8 @@ IPv4 Network Mask: 255.255.255.0# ssh developer@10.28.42.20 # or the equivalent with your ssh client+
ssh developer@10.28.42.20
# or perform the equivalent connection with your ssh client.
And then provide the password to log in.
Once the DNS services are set up (discussed in detail below), you will be able to run the much friendlier command:
-# ssh developer@cakelampvm.com+
ssh developer@cakelampvm.com
It is important to set up ssh key forwarding to enable your use of git repositories while logged into the VM. Key forwarding should be enabled for the VM's two fake host identities:
-cakelampvm.com+
10.28.42.20
cakelampvm.com
10.28.42.20
The cakelampvm v002 is released with the intention that it not need to be released again. Version 001 was not built with that explicit @@ -168,30 +169,49 @@
There is an update feature built into the VM that is quite easy to use. The updates are driven by the feisty meow script repository in conjunction with a local scripted command. To activate the "update - process" for your VM, run the following commands on the VM (without the - initial '#' symbol):
-# rpuffer $FEISTY_MEOW_APEX # updates to the latest version of feisty meow -# revamp_cakelampvm # enacts any configuration changes needed,+ process" for your VM, run the following commands on the VM: +
# plus fixes web folder and other permissions.
# update to the latest version of feisty meow.
rpuffer $FEISTY_MEOW_APEX; reconfigure_feisty_meow
# enact any configuration changes needed, such as permissions and account setup.
+revamp_cakelampvm
+
These two commands can be run at any time to patch up your VM to the latest.
-The first command ("rpuffer ...") is also useful on its own for getting - the latest version of the feisty meow code. Run it again if there - are bug fixes you need for any of the scripts or if you would like the - most up-to-date cakelampvm documentation.
+Recent versions of feisty meow support a new "get_feisty" + command, which will behave the same as the first line above. Once + you have run the "puffer..." command above for the first time (on + cakelampvm v002), this new command becomes available.
+Here are some first steps that will make the vm your own:
# passwd+
passwd
The 'passwd' command will ask for your current password, and then for a
new password plus a verification of that new password.smbpasswd
# git config --global user.email "developer@cakelampvm.com"-
# git config --global user.name "Developer J. Cakemo"+
git config --global user.email "developer@cakelampvm.com"
+ git config --global user.name "Developer J. Cakemo"
+ (The feisty meow codebase is already configured for the developer account on the cakelampvm virtual machine.)
-[incomplete section]
-If a feature called "X forwarding" is enabled in your ssh client, then - you can start graphical applications on the VM and display them on your - local machine. This works right away on most Linux hosts, but can - also work on PCs with X window system installed. This section - describes how to set up Cygwin to run X server, which enables X11 - forwarding to your local display.
-...{insert that info}...
The cakelampvm has been set up to provide a DNS server which will answer name lookup requests on any of the sites that the cakelampvm is hosting @@ -239,11 +250,11 @@ meow 10.28.42.20. (The DNS server can be tested with nslookup, dig and other tools.)
Note that the cakelampvm DNS should be listed first, if one intends to - override any DNS names that actually exist out on the internet. Further, - we have found it most effective to have *only* the cakelampvm as your DNS - server, because a secondary DNS server can "take over" providing the name - lookups, and thus foul up DNS requests that should succeed for your - VM-hosted sites.
+ override any DNS names that actually exist out on the internet. + Further, we have found it most effective to have *only* the cakelampvm as + your DNS server, because a secondary DNS server can "take over" providing + the name lookups, and thus foul up DNS requests that should succeed for + your VM-hosted sites.If your Host PC is running Windows, see the DNS configuration section below that is tailored to that operating system.
Important Note: It behooves you to remember to switch back to a normal @@ -255,8 +266,9 @@ meow both the cakelampvm VM and on your host PC. Note: ping on Linux keeps going forever, so hit control-C when you are tired of seeing the pings:
-# ping cakelampvm.com-
# ping mapsdemo.cakelampvm.com+
ping cakelampvm.com
+
+ ping www.cakelampvm.com
Note that any other answer than 10.28.42.20 for the address is *bzzzt* wrong, and means something needs to be fixed.
If these pings succeed (which hopefully they will!), then try accessing @@ -271,7 +283,7 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com
The ipconfig tool will provide helpful information about your current networking and DNS configuration:
-> ipconfig --all+
> ipconfig /all
The DNS configuration on Windows is somewhat byzantine. The pipe characters ('|') below are used to separate the menus or tabs or dialogs to traverse. Follow this path to get to the DNS config:
@@ -289,12 +301,12 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com settings on your Host PC are right, then you may need to flush your DNS cache, and that might be sufficient to start getting the right IP address. On Windows, the command for flushing DNS is: -> ipconfig /flushdns+
> ipconfig /flushdns
and on Linux the flush DNS command can be many different things, but try these two most common options:
-# sudo service dns-clean restart # restarts the client side DNS cache.+
# restarts the client side DNS cache.
sudo service dns-clean restart
or
-# sudo service nscd restart # restarts the nscd caching server.+
# restarts the nscd caching server.
sudo service nscd restart
After, this try the pings again. If they still fail, please go back
over your DNS configuration very carefully. The cakelampvm's DNS
feature *does* actually work, but operating systems sometimes do their best
@@ -357,7 +369,7 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com
If you run into any permission problems that prevent file access, either remotely or within the VM itself, then try running this command to fix them (repeated from the section above about updating the cakelampvm):
-# revamp_cakelampvm+
revamp_cakelampvm
Afterwards, the www folder and others should allow the developer user to create new folders at will.
# mkdir ~/shared # for the guest's version of the shared folder+
# sudo mount -t vboxsf myshare ~/shared # mount the vm's share name onto the folder on the vm.
# make the guest's version of the shared folder
mkdir ~/shared
# mount the vm's share name onto the folder on the vm.
sudo mount -t vboxsf myshare ~/shared
[incomplete section]
+If a feature called "X forwarding" is enabled in your ssh client, then + you can start graphical applications on the VM and display them on your + local machine. This works right away on most Linux hosts, but can + also work on PCs with X window system installed. This section + describes how to set up Cygwin to run X server, which enables X11 + forwarding to your local display.
+...{insert that info}...
Note: these instructions, even the quick approaches below, pale in comparison to the ease of use of the "standup" command in feisty meow's @@ -404,18 +425,18 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com details on how to add a containing domain for the first time.
Run this command in a bash shell on the VM:
-# add_domain excalibur.cakelampvm.com+
add_domain excalibur.cakelampvm.com
Done.
Note: the manual approach is not compatible with later use of feisty meow's "remove_domain".
Execute the following command to edit the DNS file for the cakelampvm domain: -# sudo vi /etc/bind/cakelampvm.com.conf+
sudo vi /etc/bind/cakelampvm.com.conf
Add a stanza for the new site at the end of this file:
excalibur.cakelampvm.com. IN A 10.28.42.20
IN HINFO "linux server" "ubuntu"
Restart the DNS server:
-# sudo service bind9 restart+
sudo service bind9 restart
Afterwards, pinging excalibur.cakelampvm.com should work from both the guest VM and the host PC.
# add_domain excalibur.tv+
add_domain excalibur.tv
Done.
Note: the manual approach is not compatible with later use of feisty @@ -441,7 +462,7 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com to add the new file by adding this bit of configuration at the end:
zone "excalibur.tv" in {
file "/etc/bind/excalibur.tv.conf";
type master;
allow-query { any; };
};
Restart the DNS server:
-# sudo service bind9 restart+
sudo service bind9 restart
Afterwards, pinging excalibur.tv should work from both the guest and the host.
Run this command in a bash shell on the VM:
-# add_apache_site excalibur excalibur.tv+
add_apache_site excalibur excalibur.tv
(The first parameter is the application name, the second is the domain name.)
Done.
@@ -471,21 +492,21 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com appropriate file name that includes the site's domain name. We will call our config file "excalibur.tv.conf". If you developed the file in your home folder, this would be the command to move it up to Apache: -# sudo cp ~/excalibur.tv.conf /etc/apache2/sites-available+
sudo cp ~/excalibur.tv.conf /etc/apache2/sites-available
Then tell apache to use the new file:
-# sudo a2ensite excalibur.tv # the '.conf' portion of the filename is unnecessary for this command. +href="http://nvie.com/posts/a-successful-git-branching-model/">http://nvie.com/posts/a-successful-git-branching-model/sudo a2ensite excalibur.tv
# the '.conf' portion of the filename is unnecessary for this command.Finally, restart apache to get it to begin serving the site:
-# sudo service apache2 restart+sudo service apache2 restart
Test the new web site
Given the configuration above, your host PC should now be able to access the new website on the domain "excalibur.tv".
To test this, first try pinging the new DNS name:
-# ping excalibur.tv-If there are responses to the ping *and* the answer is 10.28.42.20, then - it means the DNS is working. If there are no responses or it's some - other IP address talking back, check the instructions in the above DNS - sections.
+ping excalibur.tv
+If there are responses to the ping *and* + the answer is 10.28.42.20, then it means the DNS is working.
+If there are no responses or it's some other IP address talking back, + check the instructions in the above DNS sections.
Once the DNS is working, try browsing to the site at "http://excalibur.tv". That should at least bring up the configured site storage path, even if nothing is @@ -502,23 +523,22 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com
This is a basic guide to the Google Developer Console and API Key management: Google - API Docs
-+ API Docs
Meld is a great comparison tool that displays differences between two files or directories or directory trees in a graphical view. Meld is pre-installed on the VM. This tool can be launched either in the VM's X Windowing System (on the console) or if X11 forwarding is enabled.
To run meld, just type this command:
-#meld A B
-where A and B are either both file names or they are both directory names. - If A and B are directories, meld will compare the entire tree structure - between the two directories. It allows one to copy from one side to - the other, even if the item that needs to be copied is an entire - subdirectory.
+meld A B
+ where A and B are either both file names or they are both directory + names. If A and B are directories, meld will compare the entire tree + structure between the two directories. It allows one to copy from + one side to the other, even if the item that needs to be copied is an + entire subdirectory.
Run this command:
-# ifconfig+
ifconfig
In the results, look for "inet addr". There may be more than one, if there are multiple network interfaces.
The standard IP address is 10.28.42.20 for the cakelampvm.
@@ -526,11 +546,11 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.comWhen you've got the DNS and everything integrated, these commands will manage the vm's state:
First, log into the guest VM:
-# ssh developer@cakelampvm.com+
ssh developer@cakelampvm.com
Then, to reboot the guest VM:
-# sudo reboot+
sudo reboot
Or, to halt the guest VM:
-# sudo shutdown -h now+
sudo shutdown -h now
Using these commands is kinder to the VM than just cycling the power from the Virtualbox control panel.
# sudo mount /dev/sr0 /media/cdrom+
sudo mount /dev/sr0 /media/cdrom
Linux will mention that the device is mounted "read-only".
# cd /media/cdrom+
# sudo sh VBoxLinuxAdditions.run
cd /media/cdrom
sudo sh VBoxLinuxAdditions.run
To minimize the size used for the disk image, there are three major steps.
1. While running the VM, run this command:
-# sudo apt clean+
sudo apt clean
This throws away any cached data from the apt tool, which can be substantial.
If there are other junk files you know of that can be removed, delete @@ -593,12 +613,12 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com
2. Reboot the VM to the gparted ISO image (available at the gparted site) and run the following command:
-# sudo zerofree /dev/sda+
sudo zerofree /dev/sda
This sets all free space to the zero byte, enabling Virtualbox to free that space in the next step.
3. Shut the vm down after zerofree is complete and run this command on the host PC (this is the Linux version of the command):
-# VBoxManage modifyhd --compact ~/cake_lamp_vm/cake-lamp-vm-hd.vdi+
VBoxManage modifyhd --compact ~/cake_lamp_vm/cake-lamp-vm-hd.vdi
Replace the ~/cake_lamp_vm path with the real VM storage path. This command compacts the root (and only) partition of the VM.
@@ -625,8 +645,6 @@ href="http://mapsdemo.cakelampvm.com">http://mapsdemo.cakelampvm.com