2019-09-05 05:21:33 +00:00
---
2020-12-01 18:09:42 +00:00
stage: Enablement
group: Distribution
2020-11-26 06:09:20 +00:00
info: To determine the technical writer assigned to the Stage/Group associated with this page, see https://about.gitlab.com/handbook/engineering/ux/technical-writing/#assignments
2019-09-05 05:21:33 +00:00
type: reference
---
2021-05-27 21:10:59 +00:00
# Apps for a testing environment **(FREE SELF)**
2019-09-05 05:21:33 +00:00
This is the GitLab Support Team's collection of information regarding testing environments,
for use while troubleshooting. It is listed here for transparency, and it may be useful
for users with experience with these tools. If you are currently having an issue with
GitLab, you may want to check your [support options ](https://about.gitlab.com/support/ )
first, before attempting to use this information.
2020-12-04 21:09:29 +00:00
NOTE:
2019-09-05 05:21:33 +00:00
This page was initially written for Support Engineers, so some of the links
are only available internally at GitLab.
## Docker
2020-05-27 09:08:30 +00:00
The following were tested on Docker containers running in the cloud. Support Engineers,
2019-09-05 05:21:33 +00:00
please see [these docs ](https://gitlab.com/gitlab-com/dev-resources/tree/master/dev-resources#running-docker-containers )
on how to run Docker containers on `dev-resources` . Other setups haven't been tested,
but contributions are welcome.
### GitLab
2019-09-11 11:13:26 +00:00
Please see [our Docker test environment docs ](../../install/digitaloceandocker.md#create-new-gitlab-container )
2019-09-05 05:21:33 +00:00
for how to run GitLab on Docker. When spinning this up with `docker-machine` , ensure
you change a few things:
1. Update the name of the `docker-machine` host. You can see a list of hosts
with `docker-machine ls` .
1. Expose the necessary ports using the `-p` flag. Docker normally doesn't
allow access to any ports it uses outside of the container, so they must be
explicitly exposed.
1. Add any necessary `gitlab.rb` configuration to the
`GITLAB_OMNIBUS_CONFIG` variable.
For example, when the `docker-machine` host we want to use is `do-docker` :
2020-01-30 15:09:15 +00:00
```shell
2019-09-05 05:21:33 +00:00
docker run --detach --name gitlab \
--env GITLAB_OMNIBUS_CONFIG="external_url 'http://$(docker-machine ip do-docker)'; gitlab_rails['gitlab_shell_ssh_port'] = 2222;" \
--hostname $(docker-machine ip do-docker) \
-p 80:80 -p 2222:22 \
gitlab/gitlab-ee:11.5.3-ee.0
```
### SAML
#### SAML for Authentication
2022-05-03 21:08:54 +00:00
In the following examples, when replacing `<GITLAB_IP_OR_DOMAIN>` and `<SAML_IP_OR_DOMAIN>` it is important to prepend your IP or domain name, with the protocol (`http://` or `https://` ) being used.
2019-10-01 03:05:57 +00:00
We can use the [`test-saml-idp` Docker image ](https://hub.docker.com/r/jamedjo/test-saml-idp )
2019-09-05 05:21:33 +00:00
to do the work for us:
2020-01-30 15:09:15 +00:00
```shell
2019-09-05 05:21:33 +00:00
docker run --name gitlab_saml -p 8080:8080 -p 8443:8443 \
-e SIMPLESAMLPHP_SP_ENTITY_ID=< GITLAB_IP_OR_DOMAIN > \
-e SIMPLESAMLPHP_SP_ASSERTION_CONSUMER_SERVICE=< GITLAB_IP_OR_DOMAIN > /users/auth/saml/callback \
-d jamedjo/test-saml-idp
```
2019-09-11 11:13:26 +00:00
The following will also need to go in your `/etc/gitlab/gitlab.rb` . See [our SAML docs ](../../integration/saml.md )
2019-09-05 05:21:33 +00:00
for more, as well as the list of [default usernames, passwords, and emails ](https://hub.docker.com/r/jamedjo/test-saml-idp/#usage ).
```ruby
gitlab_rails['omniauth_enabled'] = true
gitlab_rails['omniauth_allow_single_sign_on'] = ['saml']
gitlab_rails['omniauth_sync_email_from_provider'] = 'saml'
gitlab_rails['omniauth_sync_profile_from_provider'] = ['saml']
gitlab_rails['omniauth_sync_profile_attributes'] = ['email']
gitlab_rails['omniauth_auto_sign_in_with_provider'] = 'saml'
gitlab_rails['omniauth_block_auto_created_users'] = false
gitlab_rails['omniauth_auto_link_ldap_user'] = false
gitlab_rails['omniauth_auto_link_saml_user'] = true
gitlab_rails['omniauth_providers'] = [
{
"name" => "saml",
"label" => "SAML",
"args" => {
assertion_consumer_service_url: '< GITLAB_IP_OR_DOMAIN > /users/auth/saml/callback',
idp_cert_fingerprint: '119b9e027959cdb7c662cfd075d9e2ef384e445f',
idp_sso_target_url: '< SAML_IP_OR_DOMAIN > :8080/simplesaml/saml2/idp/SSOService.php',
issuer: '< GITLAB_IP_OR_DOMAIN > ',
name_identifier_format: 'urn:oasis:names:tc:SAML:2.0:nameid-format:persistent'
}
}
]
```
#### GroupSAML for GitLab.com
2021-04-26 21:10:25 +00:00
See [the GDK SAML documentation ](https://gitlab.com/gitlab-org/gitlab-development-kit/blob/main/doc/howto/saml.md ).
2019-09-05 05:21:33 +00:00
2019-10-01 03:05:57 +00:00
### Elasticsearch
2019-09-05 05:21:33 +00:00
2020-01-30 15:09:15 +00:00
```shell
2019-09-05 05:21:33 +00:00
docker run -d --name elasticsearch \
-p 9200:9200 -p 9300:9300 \
-e "discovery.type=single-node" \
docker.elastic.co/elasticsearch/elasticsearch:5.5.1
```
2020-12-09 06:09:41 +00:00
Then confirm it works in the browser at `curl "http://<IP_ADDRESS>:9200/_cat/health"` .
2019-10-01 03:05:57 +00:00
Elasticsearch's default username is `elastic` and password is `changeme` .
2019-09-05 05:21:33 +00:00
2020-11-28 21:09:37 +00:00
### Kroki
See [our Kroki docs ](../integration/kroki.md#docker )
on running Kroki in Docker.
2019-09-05 05:21:33 +00:00
### PlantUML
See [our PlantUML docs ](../integration/plantuml.md#docker )
on running PlantUML in Docker.
### Jira
2020-01-30 15:09:15 +00:00
```shell
2019-09-05 05:21:33 +00:00
docker run -d -p 8081:8080 cptactionhank/atlassian-jira:latest
```
Then go to `<IP_ADDRESS>:8081` in the browser to set it up. This requires a
Jira license.
### Grafana
2020-01-30 15:09:15 +00:00
```shell
2019-09-05 05:21:33 +00:00
docker run -d --name grafana -e "GF_SECURITY_ADMIN_PASSWORD=gitlab" -p 3000:3000 grafana/grafana
```
Access it at `<IP_ADDRESS>:3000` .