Ask Your Question
0

Error 500: Could not find declared class

asked 2016-12-16 11:40:11 -0500

Davies gravatar image

I have a dedicated server. It runs CoreOS->Docker->puppet/puppetserver-standalone, committed once certificates had been set up as sa0001. This is started with the command

docker run -d --restart unless-stopped --name puppet -p 8140:8140 -v /home/core/modules:/etc/puppetlabs/code/environments/production/modules -v /home/core/manifests:/etc/puppetlabs/code/environments/production/manifests sa0001

The reason for using volumes is that the container has no editor (not even vi). I had been editing files outside the container and copying them in - which worked - but this is not DRY, and as the system grows, the dangers of having the wrong version somewhere will become too high for my liking. I have changed the user and permissions from inside the container. The relevant trees are (irrelevances snipped):

Outside the container:
core@puppet ~ $ ls -laR
.:
total 108
drwxr-xr-x. 5 core core 4096 Dec 15 15:06 .
drwxr-xr-x. 3 root root 4096 Nov 1 06:12 ..
drwxr-xr-x. 2 root root 4096 Dec 15 15:06 manifests
drwxr-xr-x. 3 root root 4096 Dec 15 15:01 modules

./manifests:
total 24
drwxr-xr-x. 2 root root 4096 Dec 15 15:06 .
drwxr-xr-x. 5 core core 4096 Dec 15 15:06 ..
-rwxr-xr-x. 1 root root 86 Dec 11 13:23 site.pp

./modules:
total 24
drwxr-xr-x. 3 root root 4096 Dec 15 15:01 .
drwxr-xr-x. 5 core core 4096 Dec 15 15:06 ..
drwxr-xr-x. 3 root root 4096 Dec 15 15:01 keyboard

./modules/keyboard:
total 24
drwxr-xr-x. 3 root root 4096 Dec 15 15:01 .
drwxr-xr-x. 3 root root 4096 Dec 15 15:01 ..
drwxr-xr-x. 2 root root 4096 Dec 15 15:15 manifests

./modules/keyboard/manifests:
total 32
drwxr-xr-x. 2 root root 4096 Dec 15 15:15 .
drwxr-xr-x. 3 root root 4096 Dec 15 15:01 ..
-rwxr-xr-x. 1 root root 60 Dec 11 13:33 init.pp
-rwxr-xr-x. 1 root root 462 Dec 15 15:15 microsoft.pp

Inside the container:
root@9aead11be978:/etc/puppetlabs/code# ls -laR
.:
total 32
drwxr-xr-x. 4 root root 4096 Dec 16 13:13 .
drwxr-xr-x. 1 root root 4096 Dec 8 18:48 ..
drwxr-xr-x. 3 root root 4096 Dec 9 23:39 environments
drwxr-xr-x. 2 root root 4096 Sep 1 19:21 modules

./environments:
total 24
drwxr-xr-x. 3 root root 4096 Dec 9 23:39 .
drwxr-xr-x. 4 root root 4096 Dec 16 13:13 ..
drwxr-xr-x. 5 root root 4096 Dec 9 23:39 production

./environments/production:
total 48
drwxr-xr-x. 5 root root 4096 Dec 9 23:39 .
drwxr-xr-x. 3 root root 4096 Dec 9 23:39 ..
-rw-r--r--. 1 root root 879 Sep 1 19:20 environment.conf
drwxr-xr-x. 2 root root 4096 Sep 1 19:21 hieradata
drwxr-xr-x. 2 root root 4096 Dec 15 15:06 manifests
drwxr-xr-x. 3 root root 4096 Dec 15 15:01 modules

./environments/production/hieradata:
total 16
drwxr-xr-x. 2 root root 4096 Sep 1 19:21 .
drwxr-xr-x. 5 root root 4096 Dec 9 23:39 ..

./environments/production/manifests:
total 24
drwxr-xr-x. 2 root root 4096 Dec 15 15:06 .
drwxr-xr-x. 5 root root ... (more)

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2016-12-17 15:13:01 -0500

Davies gravatar image

I found the answer with a friend's help. In my directory path, I had "keyboard" where I needed "pi_keyboard" Apologies if I've wasted anyone's time.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower

Stats

Asked: 2016-12-16 08:23:59 -0500

Seen: 58 times

Last updated: Dec 17 '16