Skip to content

Instantly share code, notes, and snippets.

@dinesh16
Last active February 26, 2019 10:37
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save dinesh16/c4c595c59a5fd9a2da33e73638c18bfd to your computer and use it in GitHub Desktop.
Save dinesh16/c4c595c59a5fd9a2da33e73638c18bfd to your computer and use it in GitHub Desktop.
Install FreeTDS and tiny_tds on codeship
#!/bin/bash
# Install FreeTDS on Codeship - http://www.freetds.org
TDS_DIR=${TDS_DIR:=$HOME/cache/freetds}
set -e
if [ ! -d "${TDS_DIR}" ]; then
mkdir -p "${HOME}/freetds"
wget "ftp://ftp.freetds.org/pub/freetds/stable/freetds-patched.tar.gz"
tar -xaf "freetds-patched.tar.gz" --strip-components=1 --directory "${HOME}/freetds"
(
cd "${HOME}/freetds" || exit 1
./configure --prefix="${TDS_DIR}"
make
make install
)
fi
ln -s "${TDS_DIR}/bin/"* "${HOME}/bin"
```
# run this as `bash path_to_file` and then run below comand
bundle config build.tiny_tds --with-freetds-lib=/home/rof/cache/freetds/lib --with-freetds-include=/home/rof/cache/freetds/include
@dinesh16
Copy link
Author

dinesh16 commented Feb 26, 2019

  • puts this file on app/bin/freetds.sh

  • run it on codeship project settings with below command

  • bash bin/freetds.sh

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment