Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • Virtual Machine (VM): VMs with root access.
  • Git: Installed on your Jenkins VM.
  • Docker :
    • To be installed in all VMs where Automatics components has to be deployed
  •  Install using the following commands:
    Code Block
    curl -fsSL https://get.docker.com -o get-docker.sh
    sh get-docker.sh
    • Create a new user group named "docker" and add the Jenkins user to this group:
      Code Block
      sudo groupadd docker
      sudo usermod -aG docker $USER
    • Log out and log back in to re-evaluate group membership. On a virtual machine, you may need to restart it. On Linux, you can also run:
      Code Block
      newgrp docker
    • Verify Docker commands can be run without sudo:
      Code Block
      docker run hello-world
    • Ensure access to pull Docker base images like Tomcat and MySQL from Docker Hub. If access is not available, ensure these images are available locally on the Jenkins VM.


  • Self Hosted Maven Artifact Repository :

    • This is where Automatics maven artifacts will be deployed and used during test execution using maven. If this setup is not available, user can skip the input reading for  maven artifact repo details. If planning to keep the artifacts in maven local repo in the same machine, please replace the command mvn deploy with mvn install in jenkins jobs configuration where ever applicable.

Jenkins Server Setup

  1. Clone the repository https://code.rdkcentral.com/r/admin/repos/rdk/tools/automatics/dev-ops(Please open the above url in browser and git clone url is available in the page) and navigate to the jenkinsServerSetup directory:

    Code Block
    git clone <repository_url>
    cd dev-ops/jenkinsServerSetup


  2. Execute the installation script as sudo:

    Code Block
    sudo sh install_jenkins_server.sh

    This script installs Docker, pulls the Jenkins server image from Docker Hub, and installs necessary dependencies like Maven and Jenkins plugins. It also creates Automatics Core & RDKB Utils build jobs and build and deployment jobs.

  3. During script execution, provide inputs such as the port for the Jenkins server. After setup, access Jenkins via the browser using the public IP and port (e.g., 192.168.91.44:8909).

  4. Configure Jenkins security:

    • Go to "Manage Jenkins" → "Security".
    • Under Security Realm, select Jenkins’ own user database.
    • In the Authorization section, select "Logged-in users can do anything".
    • Unselect "Allow anonymous read access".
    • Click "Save".
  5. Modify the necessary configurations in the pre-created Jenkins jobs (e.g., Maven repo URL, shell script file paths).

...