mirror of
https://github.com/ansible-collections/community.general.git
synced 2024-09-14 20:13:21 +02:00
ac492476e5
* Remove unused imports. * Clean up ConfigParser usage in ansible-test. * Fix bare except statements in ansible-test. * Miscellaneous cleanup from PyCharm inspections. * Enable pylint no-self-use for ansible-test. * Remove obsolete pylint ignores for Python 3.7. * Fix shellcheck issuers under newer shellcheck. * Use newer path for ansible-test. * Fix issues in code-smell tests.
25 lines
751 B
Bash
25 lines
751 B
Bash
#!/bin/sh
|
|
|
|
set -eu
|
|
|
|
# Required for newer mysql-server packages to install/upgrade on Ubuntu 16.04.
|
|
rm -f /usr/sbin/policy-rc.d
|
|
|
|
# Support images with only python3 installed.
|
|
if [ ! -f /usr/bin/python ] && [ -f /usr/bin/python3 ]; then
|
|
ln -s /usr/bin/python3 /usr/bin/python
|
|
fi
|
|
if [ ! -f /usr/bin/pip ] && [ -f /usr/bin/pip3 ]; then
|
|
ln -s /usr/bin/pip3 /usr/bin/pip
|
|
fi
|
|
if [ ! -f /usr/bin/virtualenv ] && [ -f /usr/bin/virtualenv-3 ]; then
|
|
ln -s /usr/bin/virtualenv-3 /usr/bin/virtualenv
|
|
fi
|
|
|
|
# Improve prompts on remote host for interactive use.
|
|
# shellcheck disable=SC1117
|
|
cat << EOF > ~/.bashrc
|
|
alias ls='ls --color=auto'
|
|
export PS1='\[\e]0;\u@\h: \w\a\]\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
|
|
cd ~/ansible/
|
|
EOF
|