Skip to content

Commit 8357429

Browse files
authored
Merge pull request #55 from larsewi/buildscripts
Fixes for starter pack
2 parents 3302e36 + 3023f2f commit 8357429

3 files changed

Lines changed: 29 additions & 7 deletions

File tree

README.md

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ Configure the Masterfiles Policy Framework:
177177

178178
```
179179
cd ../masterfiles
180-
./autogen.sh --enable-debug
180+
./autogen.sh
181181
```
182182

183183
### Installing CFEngine Community on a test machine
@@ -288,6 +288,8 @@ Type logout or simply press `CTRL + D` to return to the dev machine:
288288
logout
289289
```
290290

291+
**Didn't work?** Check out [Troubleshooting](#troubleshooting)
292+
291293
From the dev machine, execute the build-remote script:
292294

293295
```
@@ -492,3 +494,23 @@ the `synced_folder` lines. So something like this:
492494
- config.vm.synced_folder ".", "/vagrant",
493495
+ config.vm.synced_folder ".", "/vagrant", type: "rsync",
494496
```
497+
498+
## Troubleshooting
499+
500+
### ssh: connect to host 192.168.56.100 port 22: Protocol not available
501+
502+
If you get the following error when trying to ssh into the buildslave from the dev machine:
503+
504+
```
505+
ssh: connect to host 192.168.56.100 port 22: Protocol not available
506+
```
507+
508+
Then I experienced the same issue. Not sure if it was an ARP cache bug or a lingering ghost VM.
509+
Nevertheless, when I tried to connect, I saw that the ARP cache was updated with a different MAC address then that of the buildslave.
510+
However, by doing the reverse connection. E.g. (run this command from your host machine):
511+
512+
```
513+
vagrant ssh buildslave -c "ping -c1 192.168.56.10"
514+
```
515+
516+
I was able to repopulate the ARP cache with the correct MAC address.

Vagrantfile

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ Vagrant.configure("2") do |config|
1111
# Use a custom box:
1212
# https://scotch.io/tutorials/how-to-create-a-vagrant-base-box-from-an-existing-one
1313
config.vm.box = "basebox"
14-
# config.vm.box = "ubuntu/focal64"
14+
# config.vm.box = "ubuntu/jammy64"
1515

1616
# make sure SSH always has host keys
1717
config.vm.provision "ssh-host-keys", type: "shell", path: "scripts/ssh-host-keys.sh"
@@ -152,7 +152,7 @@ Vagrant.configure("2") do |config|
152152

153153
# Clean test machine:
154154
config.vm.define "clean", autostart: false do |clean|
155-
clean.vm.box = "ubuntu/focal64"
155+
clean.vm.box = "ubuntu/jammy64"
156156
clean.vm.hostname = "clean"
157157
clean.vm.network "private_network", ip: "192.168.56.92"
158158
clean.vm.provider :libvirt do |v, override|
@@ -194,7 +194,7 @@ Vagrant.configure("2") do |config|
194194

195195
# Prepackage a box on disk:
196196
config.vm.define "basebox", autostart: false do |basebox|
197-
basebox.vm.box = "ubuntu/focal64"
197+
basebox.vm.box = "ubuntu/jammy64"
198198
basebox.vm.provision "bootstrap", type: "shell", path: "basebox/bootstrap.sh"
199199
basebox.ssh.insert_key = false
200200
basebox.vm.provider "virtualbox" do |v|
@@ -210,7 +210,7 @@ Vagrant.configure("2") do |config|
210210

211211
# Prepackage a box on disk:
212212
config.vm.define "buildslavebox", autostart: false do |buildslavebox|
213-
buildslavebox.vm.box = "ubuntu/focal64"
213+
buildslavebox.vm.box = "ubuntu/jammy64"
214214
buildslavebox.vm.provision "bootstrap", type: "shell", path: "buildslave/bootstrap.sh"
215215
buildslavebox.ssh.insert_key = false
216216
buildslavebox.vm.provider "virtualbox" do |v|

basebox/bootstrap.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,12 +40,12 @@ apt-get install -y cargo
4040
apt-get install -y jq
4141

4242
# Nova deps:
43-
apt-get install -y postgresql-12 postgresql-contrib-12 # libpq-dev pgadmin3
43+
apt-get install -y postgresql postgresql-contrib # libpq-dev pgadmin3
4444
apt-get install -y libpgtypes3 libecpg-dev libldap2-dev librsync-dev
4545
apt-get install -y software-properties-common
4646
add-apt-repository -y ppa:ondrej/php
4747
apt-get update -y
48-
apt-get install -y php7.3-dev
48+
apt-get install -y php-dev
4949

5050
# mingw cross compile deps:
5151
apt-get install -y dpkg-dev debhelper g++ libncurses5 pkg-config build-essential libpam0g-dev mingw-w64

0 commit comments

Comments
 (0)