Skip to content

Instantly share code, notes, and snippets.

@prasadrahul
Last active January 10, 2022 03:49
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 prasadrahul/e628557e3144c36add41b5d315449c28 to your computer and use it in GitHub Desktop.
Save prasadrahul/e628557e3144c36add41b5d315449c28 to your computer and use it in GitHub Desktop.
userdata_docker_openjdk_jenkins_maven
#!/bin/bash
apt-get update
apt-get upgrade
apt-get -y install apt-transport-https ca-certificates wget curl gnupg-agent software-properties-common
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
apt-key fingerprint 0EBFCD88
add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
wget -q -O - https://pkg.jenkins.io/debian-stable/jenkins.io.key | sudo apt-key add -
add-apt-repository "deb https://pkg.jenkins.io/debian-stable binary/"
apt-get -y install docker-ce docker-ce-cli containerd.io docker-compose
apt-get update
apt-get -y install openjdk-11-jdk
apt-get -y install jenkins
apt-get -y install maven
service jenkins start
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment