Hi folks have just installed commandbox via homebr...
# box-products
j
Hi folks have just installed commandbox via homebrew on a Mac; had previously been on Windows. start loads a new simple server ok but opening my long-established coldbox app in this environment fails - logs show a Java issue:
Unable to resolve com.sun.jna [15](R 15.0): missing requirement [com.sun.jna [15](R 15.0)] osgi.native;
Looks like maybe a JAVA_HOME issue, any suggestions?
b
@James Hull Pretty sure you just need to update to a newer version of Lucee which supports your Mac
5.3.10 is the latest
j
Thanks @bdw429s that’s got it going, however Coldbox now can’t see any datasources (defined in .cfconfig.json) - any idea why?
b
@James Hull That's sort of like asking a auto mechanic, "My car won't go, any idea why?" 🙂
I mean, there may be a million reasons why, but without more information I wouldn't even know what to guess
j
Wondered if it was a common issue
b
I also don't know exactly what you mean when you say ColdBox can't "see". What does that mean? Are you getting an Error?
Strictly speaking, "ColdBox" doesn't use your datasources, your code does
Also, cars not going is a common thing, but that doesn't mean blind troubleshooting is helpful 🙂
I would start by seeing if the datasource is defined in the CF admin
If not, check the server start logs (using
--verbose
) and see if CFConfig is firing
You may not even have the module installed 🤷
j
yes, throws an error. sorry, the app (written in coldbox) is looking for a named datasource defined in cfconfig. works fine elsewhere, this is the pains of importing into a new env
b
What troubleshooting steps have you taken so far?
j
so need to install cfconfig again in commandbox?
b
I have no idea
These are things for you to research
I can't see your system modules and you haven't shared them here so I can't say what you do or do not have installed
If you are asking if CFConfig needs to be installed in order to work, the answer is yes 🙂
j
probably a little confused as to what’s in a git repo already (i.e. when creating a build to deploy via e.g. docker) vs local needs
b
Let's back up- CFConfig is not a core feature of CommandBox. It must be installed before anything will happen with your
.cfconfig.json
files
It does come pre-installed on our
ortussolutions/commandbox
docker images, but in any other situation, it's up to you to install it
If you're not sure if you've installed it, you probably haven't, lol
But you can check in 1 second by running
Copy code
list --system
If you don't see
commandbox-cfconfig
in the list, then it's not installed
Also, the
server start --verbose
console output won't have a "CFConfig" section in it if it's not installed
j
yeah I won’t have installed it local (new machine) - thanks for the info on docker image- that explains why it works there
b
But just because there's a JSON file in your folder doesn't necessarily mean anything is going to happen with it
Another module I think we bundle in our docker images which you may be using is
commandbox-dotenv
You'll need that one too if you're doing anything with
.env
files
j
ok thanks