Jenkins

https://wiki.jenkins-ci.org/display/JENKINS/Installing+Jenkins+on+Ubuntu

wget -q -O - https://pkg.jenkins.io/debian/jenkins-ci.org.key | sudo apt-key add -
sudo sh -c 'echo deb http://pkg.jenkins.io/debian-stable binary/ > /etc/apt/sources.list.d/jenkins.list'
sudo apt-get update
sudo apt-get install jenkins
ryoji@ubuntu:~$ sudo systemctl start jenkins.service
ryoji@ubuntu:~$ sudo systemctl status jenkins.service
● jenkins.service - LSB: Start Jenkins at boot time
   Loaded: loaded (/etc/init.d/jenkins; bad; vendor preset: enabled)
   Active: active (exited) since Wed 2017-03-08 23:17:08 GMT; 2min 33s ago
     Docs: man:systemd-sysv-generator(8)

Mar 08 23:17:06 ubuntu systemd[1]: Starting LSB: Start Jenkins at boot time...
Mar 08 23:17:07 ubuntu jenkins[3732]:  * Starting Jenkins Continuous Integration
Mar 08 23:17:07 ubuntu su[3761]: Successful su for jenkins by root
Mar 08 23:17:07 ubuntu su[3761]: + ??? root:jenkins
Mar 08 23:17:07 ubuntu su[3761]: pam_unix(su:session): session opened for user j
Mar 08 23:17:08 ubuntu jenkins[3732]:    ...done.
Mar 08 23:17:08 ubuntu systemd[1]: Started LSB: Start Jenkins at boot time.
Mar 08 23:19:35 ubuntu systemd[1]: Started LSB: Start Jenkins at boot time.

/file/Jenkins/jenkins.png
/file/Jenkins/install_jenkins.png

EC2

See EC2

wget https://updates.jenkins-ci.org/download/war/2.57/jenkins.war
[root@ip-172-31-23-192 ~]# mv jenkins.war /opt/wildfly/standalone/deployments/
[root@ip-172-31-23-192 ~]# service wildfly start

jen_aws.png
wildfly_initd.png

JDK
http://blog.de-gouveia.eu/2014/05/21/java-8-jdk-linux-installation-in-ec2-linux-instance/
Maven
https://gist.github.com/sebsto/19b99f1fa1f32cae5d00
mvn_home.png
jre path has to be JDK's jre

git_plugin.png
-

cd /opt
wget http://mirror.catn.com/pub/apache/maven/maven-3/3.5.0/binaries/apache-maven-3.5.0-bin.tar.gz
/opt/apache-maven-3.5.0/bin
[root@ip-172-31-23-192 ec2-user]# mkdir /home/wildfly/.ssh
[root@ip-172-31-23-192 ec2-user]# chown wildfly /home/wildfly/.ssh
[root@ip-172-31-23-192 ec2-user]# chgrp wildfly /home/wildfly/.ssh
[root@ip-172-31-23-192 ec2-user]# ls -ld /home/wildfly/.ssh
drwxr-xr-x 2 wildfly wildfly 4096 Apr 29 17:13 /home/wildfly/.ssh

[root@ip-172-31-23-192 ec2-user]# chgrp wildfly /home/wildfly
[root@ip-172-31-23-192 .ssh]# passwd wildfly
Changing password for user wildfly.
New password: 
Retype new password: 
passwd: all authentication tokens updated successfully.
[root@ip-172-31-23-192 .ssh]# su wildfly
 ssh-keygen -t rsa -b 4096 -C "@gmail.com"
 cat id_rsa.pub

bash-4.2$ git ls-remote -h git@github.com:growingspaghetti/23-feb-2017-ljc-testing-in-java.git 
The authenticity of host 'github.com (192.30.253.113)' can't be established.
Are you sure you want to continue connecting (yes/no)? yes
Warning: Permanently added 'github.com,192.30.253.113' (RSA) to the list of known hosts.
f39ddf7e41c0a22889e4cf9776ad5f426c321d03	refs/heads/master
export PATH=$PATH:/opt/apache-maven-3.5.0/bin/

jenkins_completed.png

Local repo

cat ~/.ssh/id_rsa.pub | ssh -i ~/.ssh/.pem wildfly@ecmazonaws.com "cat >> .ssh/authorized_keys"

file:///home/wildfly/git
    last modified: 29 April 2017 [ View wiki source Close ]
     
SEARCH DIFFERENCE ATTACHMENT RECENT POST