I am building an environment for my project using Docker. In order to interact with SQLAnywhere database I need PHP7 (actually for my project build with Lumen framework), SQLAnywhere 17 client and PHP7 extension for SQLAnywhere. I have already managed to add PHP7 and PHP7 extension for SQLAnywhere to my project using Docker. Current Dockerfile:

FROM php:7.3.2-fpm

WORKDIR /var/www

RUN apt-get update && apt-get install -y libmcrypt-dev libzip-dev unzip git libjpeg-dev libpng-dev wget \
    && pecl install mcrypt-1.0.2 \
    && docker-php-ext-enable mcrypt \
    && docker-php-ext-configure zip --with-libzip \
    && docker-php-ext-configure gd --with-jpeg-dir=/usr/lib/x86_64-linux-gnu \
    && docker-php-ext-install mbstring pdo_mysql zip gd

# Install Composer
RUN curl -sS https://getcomposer.org/installer | php \
    && mv composer.phar /usr/local/bin/ \
    && ln -s /usr/local/bin/composer.phar /usr/local/bin/composer

# Install SQL Anywhere client
RUN wget http://d5d4ifzqzkhwt.cloudfront.net/sqla17developer/bin/sqla17developerlinux.tar.gz -P /opt/sqlanywhere17/installation \
    && tar zxvf /opt/sqlanywhere17/installation/sqla17developerlinux.tar.gz -C /opt/sqlanywhere17/installation \
    && /opt/sqlanywhere17/installation/sqlany17/setup \
    && rm -rf /opt/sqlanywhere17/installation

# Install SQL Anywhere php extension
RUN curl http://d5d4ifzqzkhwt.cloudfront.net/drivers/php/SQLAnywhere-php-7.0_Linux.tar.gz | tar xz \
    && mv lib64/php-7.0.0_sqlanywhere.so /usr/local/lib/php/extensions/no-debug-non-zts-20180731 \
    && chown root:root /usr/local/lib/php/extensions/no-debug-non-zts-20180731/php-7.0.0_sqlanywhere.so \
    && chmod 644 /usr/local/lib/php/extensions/no-debug-non-zts-20180731/php-7.0.0_sqlanywhere.so \
    && rm -rf lib32 && rm -rf lib64

However, I cannot install SQLAnywhere client, because installation process is interactive and I cannot input any values while installation on Docker build (it stacks on first step of choosing "country & region" and keeps running constantly). Is there any non-interactive client installation? Or maybe I can pass parameters to client installation like the following:

./setup -parameter1 parameter1_value .... -parameterN parameterN_value

PS: This is the error I get multiple times in row, when installation script prompts me to enter "country & region":

TERM environment variable not set.

asked 26 May, 06:35

ilyas_khametov's gravatar image

ilyas_khametov
46349
accept rate: 100%

edited 26 May, 06:42


I don't know anything about Docker, but you might be able to do silent command-line installs, documented

here for linux and here for Windows

permanent link

answered 26 May, 06:45

Terry%20Wilkinson's gravatar image

Terry Wilkinson
616212643
accept rate: 25%

Thank you very much, seems that it works. However, it says that registration key is required in silent mode. But in the email sent by SAP it is clearly said that "There is no key required to install the SAP SQL Anywhere 17 Developer Edition". How can I obtain a key for sa17-developer?

(26 May, 07:18) ilyas_khametov

Oh, the Developer Edition - I ran into that too and was never able to find a way around it. There doesn't seem to be a way to supply a 'blank' key. I reported it to SAP quite a while ago (https://sqlanywhere-forum.sap.com/questions/26778/how-to-do-silent-install-of-developer-edition-ie-with-no-regkey) but it's been a long time since the Developer Edition has been updated.

(26 May, 07:26) Terry Wilkinson

You might also be able to do a silent setup via the Deplyoment Wizard - I have not used that tool on Linux but it is very convenient to install client software on Windows.

Note, however that redistribution of files is subject to your license agreement, and I don't know whether a Developer Edition does fit these requirements...

permanent link

answered 27 May, 03:37

Volker%20Barth's gravatar image

Volker Barth
33.7k330486714
accept rate: 33%

No matter what strategy or tooling used to distribute SQL Anywhere, redistribution of files is subject to your license agreement. No statements in this response override anything in your license agreement. Check your license agreement before considering deployment.

As suggested by Volker, the Developer Edition license does not permit deployment. The Silent Install is technically a deployment tool which requires a license key valid for deployment purposes.

Putting a copy of the Developer Edition on a shared location for installation purposes appears to violate the licensed use. Specifically, there would be a term that limits a single Developer Edition install to lay down one copy of each component - with a provision for copies to be used for testing purposes.

As to the Deployment Wizard, it generates a list of files to be deployed which is then used by the tar command. There are a few quirks with the tool that may require some manually editing of the generated file (to remove file references that may not exist in a given installation) - this was recently discovered and is being investigated but no fix has been completed yet. These issues can be easily worked around by editing them out of the file. Again, this mechanism to redistribute files must adhere to the license.

(27 May, 12:50) Chris Keating
Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×135
×58
×16

question asked: 26 May, 06:35

question was seen: 161 times

last updated: 27 May, 12:50