Hey All,
I know this problem is going around, but I don't know a valid solution for this.
I have run the dispatcher validation against all my code (inside dispatcher project). It has passed everything, but I get the same error:
2021/11/11 14:05:23 Dispatcher configuration validation failed:
conf.dispatcher.d/enabled_farms/default.farm:1: extra characters following label "/default.farm" are ignored
Does anyone know the best way to fix this on a windows box?
Solved! Go to Solution.
Views
Replies
Total Likes
So for the record, it is a symlink issue. when you run your dispatchers locally you need to have ../available_vhost/name.vhost in your symlink, but that can't be what goes into the cloud. So I got on Ubuntu WSL and did a symlink and commited it and it worked.
I want to add a couple of things.....when I used WSL to create the symlink, I was able to get rid of the above error for farm, but when I try to create the symlink for the enabled_vhost I get this:
Cloud manager validator 2.0.34
2021/11/11 15:18:48 /tmp/dispatcher/unzippedConfiguration: no file found matching pattern: conf.d/enabled_vhosts/*.vhost
The command '/bin/sh -c AZCOPY="/usr/bin/azcopy" VALIDATOR_BINARY="/usr/bin/dispatcher-configuration-validator" HTTPD_BINARY="/usr/sbin/httpd" DISPATCHER_CONFIGURATION_LOCATION=$dispatcherConfigurationLocation DISPATCHER_CONFIGURATION_DESTINATION=$dispatcherConfigurationDestination DISPATCHER_IMAGE=$dispatcherImage RUN_MODE=$runmode ./validateDispatcherConfiguration.sh' returned a non-zero code: 2
2021/11/11 15:18:48 Container failed during run: validate-dispatcher. No retries remaining.
failed to run step ID: validate-dispatcher: exit status 2
That is not true, the file is there.
The problem is:
enabled_vhosts/wknd.vhost needs to be a symboling link to available_vhosts/wknd.vhost
(see repo on git)
https://github.com/adobe/aem-guides-wknd/blob/master/dispatcher/src/conf.d/enabled_vhosts/wknd.vhost
But on client package this is a plain file containing
../available_vhosts/wknd.vhost
Can you please try to fix the symbolic link and run the validator locally to see if you still get an error.
Yeah I know, and I have been doing that. Still getting the error.
So for the record, it is a symlink issue. when you run your dispatchers locally you need to have ../available_vhost/name.vhost in your symlink, but that can't be what goes into the cloud. So I got on Ubuntu WSL and did a symlink and commited it and it worked.
I was referring to the blog - https://medium.com/tech-learnings/aem-dispatcher-configurations-symlinks-8f52f554ffa5
Do we mandatorily need Ubuntu WSL ? Shouldn't the mklink utility work ?
I was able to create symlinks in my local (Windows 11 machine) using this utility.
Will this not work on cloud instance ?
As per the blog -
The mklink utility was working without any issues, able to deploy the dispatcher configurations to AMS server with the symlink created through mklink in windows machine(easy to use the utility in windows and not require any additional configurations — my recommended option for windows)
Views
Replies
Total Likes
yes mklink does work. I have done both wsl and mklink. making symlinks with wsl was a little easier then mklink....but I just created a symlink using mklink and everything was great. The only issue was I had to use git commands to upload as gitkraken was giving me issues
Views
Likes
Replies
Views
Likes
Replies