Last active
September 30, 2016 22:20
-
-
Save cnauroth/bd7ac7e44ef8d41168c5a8031bc017e8 to your computer and use it in GitHub Desktop.
EC2 Hadoop Build Environment Login Greeting
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# .bash_profile | |
# Get the aliases and functions | |
if [ -f ~/.bashrc ]; then | |
. ~/.bashrc | |
fi | |
# User specific environment and startup programs | |
#export JAVA_HOME=/etc/alternatives/java_sdk_1.7.0_openjdk | |
export JAVA_HOME=/etc/alternatives/java_sdk_1.8.0_openjdk | |
export MAVEN_HOME=~/apache-maven-3.3.9 | |
PATH=$PATH:$HOME/.local/bin:$HOME/bin:$JAVA_HOME/bin:$MAVEN_HOME/bin | |
export PATH | |
echo " | |
EC2 Hadoop Build Environment | |
== HOST =================================================================== | |
- Hostname........: $HOSTNAME | |
- User............: $USER | |
== EC2 ==================================================================== | |
- Instance ID.....: $(curl http://169.254.169.254/latest/meta-data/instance-id 2>/dev/null) | |
- Instance Type...: $(curl http://169.254.169.254/latest/meta-data/instance-type 2>/dev/null) | |
- Public Hostname.: $(curl http://169.254.169.254/latest/meta-data/public-hostname 2>/dev/null) | |
- Public IP.......: $(curl http://169.254.169.254/latest/meta-data/public-ipv4 2>/dev/null) | |
- Local Hostname..: $(curl http://169.254.169.254/latest/meta-data/local-hostname 2>/dev/null) | |
- Local IP........: $(curl http://169.254.169.254/latest/meta-data/local-ipv4 2>/dev/null) | |
== SOFTWARE =============================================================== | |
- OS..............: $(cat /etc/redhat-release) | |
- Java............: $(java -version 2>&1 | head -1) | |
- Maven...........: $(mvn -version | head -1 | cut -d' ' -f1-3) | |
- Protoc..........: $(protoc --version) | |
- CMake...........: $(cmake -version) | |
- GCC.............: $(gcc --version | head -1) | |
=========================================================================== | |
" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment