Skip to content

Commit

Permalink
Clarify linux package installs re: recommended packages
Browse files Browse the repository at this point in the history
  • Loading branch information
chadlwilson committed Nov 2, 2024
1 parent e08b4c5 commit 22afc28
Show file tree
Hide file tree
Showing 8 changed files with 39 additions and 41 deletions.
2 changes: 1 addition & 1 deletion content/advanced_usage/ui_testing.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ The next step is to start the GoCD agent as an application.

There are many different ways to get a Linux build agent to interact with a UI. The easiest is to use a VNC service (or `xvfb`) to provide a dedicated X11 server to your agent. To do this:

1. Install the VNC server and fvwm packages for your distribution. (aptitude install vnc4server fvwm / yum install vnc-server fvwm)
1. Install the VNC server and fvwm packages for your distribution. (apt-get install vnc4server fvwm / dnf install vnc-server fvwm)
2. Sudo to the 'go' user (sudo su - go) and do the rest as that user
3. Set a password for remote access to your VNC server with the command 'vncpasswd'
4. Edit your VNC config to use fvwm and not twm as the window manager. (replace twm with fvwm in \~/.vnc/xstartup)
Expand Down
4 changes: 2 additions & 2 deletions content/extension_points/package_repository_extension.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,15 +20,15 @@ These files (packages) are often maintained in corresponding package repositorie

### Supported Packages

Since there are many package formats each with its own package manager and repository, the support for package-as-material has been implemented as an extension point. Using the [yum-repo-poller plugin](yum_repository_poller.html), it is possible to specify an rpm package held in a yum repository as a material for a GoCD pipeline. Using other [external plugins](https://www.gocd.org/plugins/), it is possible to do the same for other types of packages.
Since there are many package formats each with its own package manager and repository, the support for package-as-material has been implemented as an extension point. Using the [yum-repo-poller plugin](yum_repository_poller.html), it is possible to specify an rpm package held in a dnf/yum repository as a material for a GoCD pipeline. Using other [external plugins](https://www.gocd.org/plugins/), it is possible to do the same for other types of packages.

### Repositories, Packages and Materials

A repository may contain one or more packages. A pipeline may refer to a package as a material. When the package is updated in the repository, interested pipelines will get scheduled.

#### Repository Definition

A package material plugin lets pipeline group admins provide details of the corresponding repository type to GoCD. e.g. here is how we define a yum repository using the [yum-repo-poller plugin](yum_repository_poller.html).
A package material plugin lets pipeline group admins provide details of the corresponding repository type to GoCD. e.g. here is how we define a dnf/yum repository using the [yum-repo-poller plugin](yum_repository_poller.html).

##### Note:

Expand Down
30 changes: 17 additions & 13 deletions content/installation/install/agent/linux.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The GoCD agent RPM installer has been tested on RedHat Enterprise Linux and Cent
Once you have the repository setup, execute

```shell
sudo yum install -y go-agent
sudo dnf install -y go-agent
```

Alternatively, if you have the agent RPM [downloaded](https://www.gocd.org/download):
Expand All @@ -33,7 +33,7 @@ The GoCD agent .deb installer has been tested on Ubuntu. However it should work
Once you have the repository setup, execute

```shell
sudo apt-get install go-agent
sudo apt-get install --install-recommends go-agent
```

Alternatively, if you have the agent DEB [downloaded](https://www.gocd.org/download):
Expand All @@ -42,6 +42,10 @@ Alternatively, if you have the agent DEB [downloaded](https://www.gocd.org/downl
sudo dpkg -i go-agent-${version}.deb
```

Recommended dependencies are installed by default on most distributions so the option isn't needed, however if you
choose not to install such dependencies you will need to install your own JRE and configure GoCD to use it in
`wrapper-properties.conf` located within the configuration directory specified below.

## Install on Docker containers

{{< include file="installation/install/_install_on_containers.md" markdown="true" service_name="agent" >}}
Expand All @@ -50,24 +54,24 @@ sudo dpkg -i go-agent-${version}.deb

The GoCD agent script must be run with one of the following arguments:

| Script | Description |
| -------------------------------------------------- | ------------------------------------------------------------------------ |
| service go-agent console | The GoCD agent will be started in the foreground |
| service go-agent start | The GoCD agent will be started as a daemon in the background |
| service go-agent stop | The GoCD agent will be stopped |
| service go-agent restart | The GoCD agent will be restarted |
| Script | Description |
|--------------------------| ------------------------------------------------------------------------ |
| service go-agent console | The GoCD agent will be started in the foreground |
| service go-agent start | The GoCD agent will be started as a daemon in the background |
| service go-agent stop | The GoCD agent will be stopped |
| service go-agent restart | The GoCD agent will be restarted |

`service` utilizes the service manager (e.g systemd, upstart, init.d) used by your OS.

## Location of GoCD agent files

The GoCD agent installs its files in the following locations on your filesystem:

| Location | Description |
| ---------------------------------------------------- | ----------------------------------------------------- |
| `/var/lib/go-agent` | the GoCD agent configuration and working directory |
| `/var/log/go-agent` | the GoCD agent log files |
| `/usr/share/go-agent` | the GoCD agent binaries and startup scripts |
| Location | Description |
|--------------------------------------------------------------| ----------------------------------------------------- |
| `/var/lib/go-agent` | the GoCD agent configuration and working directory |
| `/var/log/go-agent` | the GoCD agent log files |
| `/usr/share/go-agent` | the GoCD agent binaries and startup scripts |
| `/usr/share/go-agent/wrapper-config/wrapper-properties.conf` | the configuration file to alter GoCD agent properties |

## Configuring the GoCD agent
Expand Down
20 changes: 12 additions & 8 deletions content/installation/install/server/linux.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ The GoCD server RPM installer has been tested on RedHat Enterprise Linux and Cen
Once you have the repository setup, execute

```shell
sudo yum install -y go-server
sudo dnf install -y go-server
```

Alternatively, if you have the server RPM [downloaded](https://www.gocd.org/download):
Expand All @@ -33,7 +33,7 @@ The GoCD server .deb installer has been tested on Ubuntu. However it should work
Once you have the repository setup, execute

```shell
sudo apt-get install go-server
sudo apt-get install --install-recommends go-server
```

Alternatively, if you have the server DEB [downloaded](https://www.gocd.org/download):
Expand All @@ -42,6 +42,10 @@ Alternatively, if you have the server DEB [downloaded](https://www.gocd.org/down
sudo dpkg -i go-server-${version}.deb
```

Recommended dependencies are installed by default on most distributions so the option isn't needed, however if you
choose not to install such dependencies you will need to install your own JRE and configure GoCD to use it in
`wrapper-properties.conf` located within the configuration directory specified below.

## Install on Docker containers

{{< include file="installation/install/_install_on_containers.md" markdown="true" service_name="server" >}}
Expand All @@ -51,12 +55,12 @@ sudo dpkg -i go-server-${version}.deb

The GoCD server script must be run with one of the following arguments:

| Script | Description |
| -------------------------------------------------- | ------------------------------------------------------------------------|
| service go-server console | The GoCD server will be started in the foreground |
| service go-server start | The GoCD server will be started as a daemon in the background |
| service go-server stop | The GoCD server will be stopped |
| service go-server restart | The GoCD server will be restarted |
| Script | Description |
|----------------------------| ------------------------------------------------------------------------|
| service go-server console | The GoCD server will be started in the foreground |
| service go-server start | The GoCD server will be started as a daemon in the background |
| service go-server stop | The GoCD server will be stopped |
| service go-server restart | The GoCD server will be restarted |

`service` utilizes the service manager (e.g systemd, upstart, init.d) used by your OS.

Expand Down
2 changes: 1 addition & 1 deletion content/installation/system_requirements.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ has a number of issues compared to the desktop experience.

### Java Dependencies for GoCD (Server and Agent)

All GoCD installers except for the Generic Zip installer are bundled with an appropriate version of the JRE, hence you
All GoCD installers except for the Generic Zip installer are bundled with (or specify a package dependency on) an appropriate version of the JRE, hence you
do not need to install Java separately to run GoCD Server or Agent. If you still want to use a specific JRE, this
version of GoCD requires Java Runtime Environment (JRE) versions 17 and above.

Expand Down
4 changes: 2 additions & 2 deletions content/installation/upgrading_go.md
Original file line number Diff line number Diff line change
Expand Up @@ -51,15 +51,15 @@ Run the GoCD installer as described
sudo dpkg -i /path/to/go-server-${version}.deb
# OR
sudo apt-get update
sudo apt-get install go-server
sudo apt-get install --install-recommends go-server
```

#### RPM based distributions (i.e. RedHat)

Run the GoCD installer as described
```bash
sudo rpm -Uvh /path/to/go-server-${version}.rpm
sudo yum upgrade go-server
sudo dnf upgrade go-server
```

#### MacOS
Expand Down
16 changes: 3 additions & 13 deletions layouts/partials/installation/install/_install_on_containers.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,6 @@

To run GoCD on container please use our official [docker container images](https://hub.docker.com/u/gocd)

For installing GoCD {{ .Get "service_name" }} using rpm/deb packages on containers, starting from release `19.7.0` the following additional dependencies will be required.

On Fedora, install `procps` package, execute

```shell
sudo yum install procps
```

On CentOS/RHEL, install `sysvinit-tools` package, execute

```shell
sudo yum install sysvinit-tools
```
If it possible to install via rpm/deb packages as well, however this is not normally recommended as
the GoCD {{ .Get "service_name" }} packages are intended to be installed with an init system rather than
managed via the container entrypoint.
2 changes: 1 addition & 1 deletion layouts/partials/installation/install/_yum_repo.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
If you prefer to use the YUM repository and install via YUM, paste the following in your shell -
If you prefer to use the dnf/yum repository and install via dnf/yum, paste the following in your shell -

```bash
sudo curl https://download.gocd.org/gocd.repo -o /etc/yum.repos.d/gocd.repo
Expand Down

0 comments on commit 22afc28

Please sign in to comment.