You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: sonarqube/content.md
+56-4Lines changed: 56 additions & 4 deletions
Original file line number
Diff line number
Diff line change
@@ -55,16 +55,55 @@ By default, the image will use an embedded H2 database that is not suited for pr
55
55
56
56
Setup a database by following the "Installing the Database" section of https://docs.sonarqube.org/latest/setup/install-server/.
57
57
58
-
### Use bind-mounted folders
58
+
### Use bind-mounted folders or volumes
59
59
60
-
The images contain the SonarQube installation at `/opt/sonarqube`. You need to use bind-mounted folders to override selected files or directories :
60
+
The images contain the SonarQube installation folders at `/opt/sonarqube`. You will need to bind them to your host to override selected files or directories :
61
61
62
62
-`/opt/sonarqube/conf`: configuration files, such as `sonar.properties`
63
63
-`/opt/sonarqube/data`: data files, such as the embedded H2 database and Elasticsearch indexes
64
64
-`/opt/sonarqube/logs`: contains SonarQube logs about access, web process, CE process, Elasticsearch logs
65
65
-`/opt/sonarqube/extensions`: plugins, such as language analyzers
66
66
67
-
### First installation
67
+
### SonarQube 7.9.x LTS first installation
68
+
69
+
Follow these steps for your first installation:
70
+
71
+
1. Create volumes `sonarqube_conf`, `sonarqube_data`, `sonarqube_logs`, and `sonarqube_extensions` and start the image with the following command. This will populate all the volumes (copying default plugins, create the Elasticsearch data folder, create the sonar.properties configuration file). Watch the logs, and, once the container is properly started, you can force-exit (ctrl+c) and proceed to the next step.
2. Configure sonar.properties to configure the database JDBC URL. Templates are available for every supported database. Just uncomment and configure the template you need. Please note that due to [SONAR-12501](https://jira.sonarsource.com/browse/SONAR-12501), providing `sonar.jdbc.username` and `sonar.jdbc.password` in `sonar.properties` is not working, and you will need to explicitly define theses values in the docker run command with the `-e` flag.
3. Drivers for the supported databases (except Oracle) are already provided. Do not replace the provided drivers; they are the only ones supported. For Oracle, copy the JDBC driver into `$SONARQUBE_HOME/extensions/jdbc-driver/oracle`.
91
+
92
+
4. Run the image with your JDBC username and password :
@@ -109,11 +148,24 @@ Follow these steps for your first installation:
109
148
110
149
## Upgrade SonarQube
111
150
151
+
### From 7.9.x LTS to another 7.9.x LTS version
152
+
153
+
Take a look at the [Upgrade Guide](https://docs.sonarqube.org/latest/setup/upgrading/).
154
+
No specific Docker operations are needed, just use the new tag.
155
+
156
+
### From 7.9.x LTS to 8.x
157
+
158
+
Follow the next section instructions, but instead of upgrading from folders to folders, you will migrate your volumes to new folders.
159
+
160
+
> Starting with the version 8.0, you can move your `sonar.jdbc.username` and `sonar.jdbc.password` value to `sonar.properties` instead of passing them with the `-e` flag.
161
+
162
+
### From 8.x
163
+
112
164
Follow these steps to upgrade SonarQube:
113
165
114
166
1. Create a new `sonarqube_home_new` folder and backup your old folder.
115
167
116
-
2. Update the environment variable `$SONARQUBE_HOME` pointing to it. Backup the old one:
168
+
2. Update the environment variable `$SONARQUBE_HOME` pointing to it:
0 commit comments