• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
0

ColdFusion 10 silent installation and configuration

Explorer ,
Sep 21, 2012 Sep 21, 2012

Copy link to clipboard

Copied

Hi,

CF 10 docs seem a tad thin on the subject of silent / unattended / scripted installation and configuration.

I need to find a fully automated (scripted) way to do these things:

1) install of ColdFusion 10 server in standalone mode

2) create additional servers instances

3) configure each server instance separately (settings, data sources, mappings, etc)

Is this currently possible with CF 10? If yes, where's the documentation?

I'm aiming for a Chef cookbook for performing unattended CF10 installations on a farm of headless Linux hosts. Manual configuration through the Administrator UI is a definite deal breaker here.

Thanks in advance!

Best regards,

Jan

Views

15.9K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines

correct answers 1 Correct answer

Explorer , Sep 25, 2012 Sep 25, 2012

For convenience, a summary..

 

How to silently:

1a) install ColdFusion 10 server software: 4721871

1b) complete default server instance installation: 4722100

2) create additional servers instances: 4722350

3) configure each server instance separately: 4724683

 

Related files:

neo-security-config.sh

example-configuration.cfm

 

Br,

Jan

 

[Updated in 2021, by Charlie A, to correct the links offered. They were to Jan's various comments in this thread, but they had the form/url of the old forums, so

...

Votes

Translate

Translate
Community Expert ,
Sep 21, 2012 Sep 21, 2012

Copy link to clipboard

Copied

Jan, I can confirm there’s no reference to a silent install in the CF 10 Install guide (searched the PDF), but while there is also was no reference to it in CF9 install guide, there was in fact a blog entry from the CF team about how to do it for CF9:

http://blogs.adobe.com/cfdoc/2009/10/performing_a_silent_installation_of_coldfusion_9.html

It’s hard to know if that info would help with CF10, given the change from Jrun to Tomcat, but you may want to try it (if you have a good setup to recover if it doesn’t), or I’d recommend that you post a comment there asking if it’s possible to use that for CF10.

If you do give it a try, please do reply here (and there) to let others know how it went, if they may look for this solution and find either in a search result.

Hope that helps.

/charlie


/Charlie (troubleshooter, carehart.org)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Oct 10, 2012 Oct 10, 2012

Copy link to clipboard

Copied

I just got the list of silent installation variables for cf10

#Silent properties for ColdFusion 10 

INSTALLER_UI=SILENT

#Valid Values are full/trial/developer SILENT_LICENSE_MODE=full

SILENT_SERIAL_NUMBER=XXXX-XXXX-XXXX-XXXX-XXXX-XXXX

#Use when it is upgrade

SILENT_PREV_SERIAL_NUMBER= 

#Valid values are ear/war/standalone SILENT_INSTALLER_TYPE=standalone 

SILENT_INSTALL_ODBC=true

SILENT_INSTALL_SAMPLES=true

SILENT_INSTALL_JNBRIDGE=true

SILENT_INSTALL_ADMIN=true

SILENT_INSTALL_SOLR=true

SILENT_INSTALL_FOLDER=C:\\ColdFusion10

#enable secure profile, IP addresses from which Administrator can be accessed.

SILENT_ENABLE_SECURE_PROFILE=true

SILENT_ADMIN_IP= 

SILENT_ADMIN_USERNAME=admin

SILENT_ADMIN_PASSWORD=Adm1n$ 

SILENT_ENABLE_RDS=false

#Provide password when enable RDS is true

SILENT_RDS_PASSWORD= 

#remote username/password

SILENT_JETTY_USERNAME=admin

SILENT_JETTY_PASSWORD=Adm1n$ 

#Context Root for J2ee Installation

SILENT_CONTEXT_ROOT= 

#automatically check for serverupdates. SILENT_AUTO_ENABLE_UPDATES=true 

#Migration (applicable to non-windows OSes only) SILENT_MIGRATE_COLDFUSION=

SILENT_PREV_CF_MIGR_DIR=

I noticed that in Windows servers, passwords set in the silent installation do not do well with some special characters.

I've also noticed some discussion about touching the admin page after installation to complete the install. I think that just first touch of the admin page just triggers migration wizards. This can be bypassed by revising the file adminconfig.xml located under %installation_root%/cfusion/lib and changing <runsetupwizard>true</runsetupwizard> to <runsetupwizard>false</runsetupwizard>

I'll try to folow up later with how I am installing on our servers.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Nov 07, 2012 Nov 07, 2012

Copy link to clipboard

Copied

One more observation related to the silent installation response file: It is highly sensitive to white space.

Having eg. "SILENT_INSTALL_SOLR=true " (space between "true" and end of line) will result in Solr not being installed.

So, if you're not getting the expected results from a silent install, make white space visible in your text editor and take a closer look at the response file.

Br,

Jan

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Sep 24, 2012 Sep 24, 2012

Copy link to clipboard

Copied

Hi.

I gave it a go this morning and it seems that the CF 10 installer supports a response file like previous versions did.

Installation steps:

  1. Download the appropriate installation package for your architecture. In my case it's ColdFusion_10_WWEJ_linux64.bin
  2. Ensure your RUNTIME_USER exists before running the installer (default is nobody)
  3. Run the installer:
    sudo ./ColdFusion_10_WWEJ_linux64.bin -f installer.profile
  4. Start the default server (cfusion)
    sudo /opt/coldfusion10/cfusion/bin/coldfusion start
  5. Wait for the server to start up.
  6. Log in to the Administrator UI at http://<host>:8500/CFIDE/administrator to complete the installation.

installer.profile (example)


INSTALLER_UI=SILENT 

SILENT_LICENSE_MODE=developer
#SILENT_SERIAL_NUMBER=XXXX-XXXX-XXXX-XXXX-XXXX-XXXX  

SILENT_INSTALLER_TYPE=standalone
SILENT_CONTEXT_ROOT=/
SILENT_RUNTIME_USER=coldfusion
SILENT_INSTALL_FOLDER=/opt/coldfusion10

# Optional components and services
SILENT_INSTALL_SOLR=true
SILENT_ENABLE_RDS=false

#Passwords
SILENT_ADMIN_PASSWORD=xxxxxxxxx
SILENT_RDS_PASSWORD=xxxxxxxxx


This puts ColdFusion 10 software on a host with little effort, but it's not really ready to run an application yet. Got us a few steps closer to that goal nevertheless.

Tero Pikala kindly shared his setup scripts for CF 9. They contain nice tricks involving curl and hacking neo-security.xml for automating step 6 and additional server instance creation. It's basically a simulated browser approach. I'll take a look at that next.

Br,

Jan

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Sep 24, 2012 Sep 24, 2012

Copy link to clipboard

Copied

Ok. To automate step 6 as well, you need to

  1. Disable admin security by editing neo-security.xml
  2. Start up the server instance.
  3. Access the admin UI over HTTP to trigger some final installation steps. Don't know exactly what they are and why it has to be done like this.
  4. Shut down the server instance.
  5. Re-enable admin security in neo-security.xml

Because neo-security.xml is a pile of ugly-printed wddx mess not even meant to be human-readable, I wrote a small shell script called neo-security-config.sh to aid in modifying it. It's available here: http://pastebin.com/jAVStuJ6.

Here's my current installation script:

# Install CF
sudo ./ColdFusion_10_WWEJ_linux64.bin -f installer.profile
# Disable admin security
sudo ./neo-security-config.sh /opt/coldfusion10/cfusion false
# Start up the CF server instance and wait for a moment
sudo /opt/coldfusion10/cfusion/bin/coldfusion start; sleep 15
# Simulate a browser request on the admin UI to complete installation
wget --delete-after http://localhost:8500/CFIDE/administrator/index.cfm?configServer=true
# Stop the CF server instance
sudo /opt/coldfusion10/cfusion/bin/coldfusion stop
# Re-enable admin security
sudo ./neo-security-config.sh /opt/coldfusion10/cfusion true

This script installs ColdFusion 10 with no need for operator intervention, in less than 3 minutes (ymmv).

Br,

Jan

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Sep 24, 2012 Sep 24, 2012

Copy link to clipboard

Copied

2) Create additional server instances

In addressing need #2, working around CF 10's cross-site request forgery (CSRF) protection turned out to be the biggest hurdle.

Anyway, here's the code:

#!/bin/bash

# Create additional server instances

SERVER_NAMES="server-a server-b server-c"

COOKIEFILE="/tmp/curl-cookies-$$.txt"

CURL_CMD="curl --noproxy localhost --cookie-jar $COOKIEFILE --cookie $COOKIEFILE -s"

ENTMANURL="http://localhost:8500/CFIDE/administrator/entman"

touch $COOKIEFILE

NEXTPAGE=`$CURL_CMD $ENTMANURL/index.cfm | sed -n 's/.*action="\(addserver.cfm?servertype=addlocal[^"]*\).*/\1/p'`

NEXTPAGE=`$CURL_CMD $ENTMANURL/$NEXTPAGE | sed -n 's/.*action="\(processaddserver.cfm?[^"]*\).*/\1/p'`

for SERVER_NAME in $SERVER_NAMES; do

  echo $SERVER_NAME

  $CURL_CMD -d "serverName=$SERVER_NAME&directory=/opt/coldfusion10/$SERVER_NAME" $ENTMANURL/$NEXTPAGE > /dev/null

done

rm $COOKIEFILE

Not exactly pretty. Please let me know if you have a simpler way of doing this.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Sep 24, 2012 Sep 24, 2012

Copy link to clipboard

Copied

Great stuff. Thanks for sharing, Jan. Hope it may help others.

That said, I would still propose that you bring this up on the blog entry on the CF9 silent installer, to see what the Adobe folks may have to say. I would even propose that you offer a link back to this thread here (http://forums.adobe.com/message/4722350), so that others reading that entry could find what you've shared, if for some reason Adobe doesn't respond.

Glad the suggestion got you in the right direction, and thanks for documenting the details for getting it working as you have.


/Charlie (troubleshooter, carehart.org)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Sep 24, 2012 Sep 24, 2012

Copy link to clipboard

Copied

Charlie, commenting the original blog post is an excellent idea, thanks. I tried it, but it says "Sorry, comments are closed for this item."

I posted the comment on the CF10 online documentation page Installing ColdFusion 10 instead.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Sep 25, 2012 Sep 25, 2012

Copy link to clipboard

Copied

Wow, bummer. I just confirmed that, too. Really surprises me. I will contact folks at Adobe to get more info, if any.

/charlie


/Charlie (troubleshooter, carehart.org)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Sep 25, 2012 Sep 25, 2012

Copy link to clipboard

Copied

Step 3) configure each server instance separately (settings, data sources, mappings, etc)

Automated server instance configuration is possible using the CF Administator API. Take a look at "CFIDE.adminapi" in eg. http://localhost:8500/CFIDE/componentutils/componentdoc.cfm for details.

Server instance configuration steps:

  1. Choose the instance to be configured
  2. Ensure it is stopped
  3. Disable admin security on the instance
  4. Deploy a prepared configuration template in wwwroot.
    Example template available here: http://pastebin.com/BNFUdfk9
  5. Start up the instance
  6. Find out the built-in web server port
  7. Run the configuration template by requesting it over HTTP
  8. Stop the instance
  9. Remove the configuration template from wwwroot
  10. Re-enable admin security

In code:

CF_INSTANCE=/opt/coldfusion10/server-a
sudo $CF_INSTANCE/bin/coldfusion stop
sudo ./neo-security-config.sh $CF_INSTANCE false
sudo cp configure.cfm $CF_INSTANCE/wwwroot/
sudo $CF_INSTANCE/bin/coldfusion start; sleep 15
CF_HTTP_PORT=`grep Http11Protocol $CF_INSTANCE/runtime/conf/server.xml | sed -n 's/.*port="\([0-9]*\).*/\1/p'`
curl --noproxy localhost http://localhost:$CF_HTTP_PORT/configure.cfm
sudo $CF_INSTANCE/bin/coldfusion stop
sudo rm $CF_INSTANCE/wwwroot/configure.cfm
sudo ./neo-security-config.sh $CF_INSTANCE true

You could also do this without disabling security, but then you'd need to include the admin password in configure.cfm.

With this, I believe my three automation requirements are now satisfied. The solution is not as clean as I'd like, but usable.

Br,

Jan

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Sep 25, 2012 Sep 25, 2012

Copy link to clipboard

Copied

For convenience, a summary..

 

How to silently:

1a) install ColdFusion 10 server software: 4721871

1b) complete default server instance installation: 4722100

2) create additional servers instances: 4722350

3) configure each server instance separately: 4724683

 

Related files:

neo-security-config.sh

example-configuration.cfm

 

Br,

Jan

 

[Updated in 2021, by Charlie A, to correct the links offered. They were to Jan's various comments in this thread, but they had the form/url of the old forums, so were all just dropping users at the top of this thread. I changed them to point to the new comment URL/location.]

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Explorer ,
Mar 29, 2013 Mar 29, 2013

Copy link to clipboard

Copied

I know this is an old post, but I thought I'd point out the following chef cookbook: https://github.com/wharton/chef-coldfusion10. This cookbook installs ColdFusion 10, applies updates, can configure Apache if using opscode's apache2 cookbook, and has providers that allow you to easily configure multiple instances via the admin api. The cookbook has been under development for over a year and more enhancements are planned (for example a wsconfig LWRP). For more information see the cookbook README.

(Disclamier: I'm the primary author of the cookbook.)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jun 13, 2019 Jun 13, 2019

Copy link to clipboard

Copied

LATEST

For any who may come along to this thread later, the CF docs did eventually get updated to have what had been in the CF9 ones (for for some reason were not there at the time of this thread, in 2012, in the CF10 docs):

https://helpx.adobe.com/coldfusion/installing/installing-coldfusion-silently.html


/Charlie (troubleshooter, carehart.org)

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources
Documentation