### Windows Sample Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md Run the container in the background and get parameters from entries in the secrets folder on Windows. ```powershell $P = $PWD.Path.Replace("\", "/") docker run -d ` -v $P/secrets:C:/ProgramData/Docker/secrets:ro ` -v $P/data/cache:C:/Cache ` -v $P/data/search:C:/Search ` -v $P/data/logs:C:/Logs ` -p 9999:8080 ` -e BASEURL=http://localhost:9999/ ` oneidentity/oneim-api:latest ``` -------------------------------- ### Linux Sample Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md Run the container in the background and get parameters from entries in the secrets folder on Linux. ```sh docker run -d \ -p 9999:8080 \ -v $PWD/secrets:/run/secrets:ro \ -e BASEURL=http://localhost:9999/ \ oneidentity/oneim-api:latest ``` -------------------------------- ### Custom Dockerfile to create a simple Job Service installation (Linux) Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/installer/README.md The following Dockerfile demonstrates the usage of the `oneidentity/oneim-installer` image to create your own custom One Identity Manager Job Service container for Linux. ```Dockerfile FROM oneidentity/oneim-installer:linux-amd64-latest # Database system, supported values: MSSQL ENV DBSYSTEM MSSQL # Connection string to the database. Will be used at build. # # MS SQL connection string # ENV CONNSTRING "Data Source=;Initial Catalog=;User ID=;Password=" # Deployment targets to install ENV TARGETS "Server\Jobserver" # Assemble the One Identity Manager installation RUN dotnet /installer/create-web-dir.dll \ --mode=standalone \ --dest=${SRV_HOME} \ --db-system=$DBSYSTEM \ --db-connect="$CONNSTRING" \ --targets="$TARGETS" \ && rm -rf /installer # Copy a valid job service configuration file to the created One Identity Manager installation COPY JobService.cfg ${SRV_HOME} EXPOSE 1880 EXPOSE 2880 WORKDIR ${SRV_HOME} CMD ["dotnet", "JobServiceCmd.dll"] ``` -------------------------------- ### Windows: Run Database Agent with Connection String Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/dbagent/README.md Example command to run the Database Agent on a Windows host, providing the connection string as an environment variable. ```powershell docker run -it --rm -e "CONNSTRING=Data Source=[Server];Initial Catalog=[DB];User ID=[User];Password=[Password]" oneidentity/oneim-dbagent:latest ``` -------------------------------- ### Windows: Run Database Agent with Secrets Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/dbagent/README.md Example command to run the Database Agent on a Windows host in the background, using parameters from a secrets folder. ```powershell docker run -d -v C:/Path/To/secrets:C:/ProgramData/Docker/secrets:ro oneidentity/oneim-dbagent:latest ``` -------------------------------- ### Linux: Run Database Agent with Secrets Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/dbagent/README.md Example command to run the Database Agent on a Linux host in the background, using parameters from a secrets folder. ```sh docker run -d -v -v $PWD/secrets:/run/secrets:ro oneidentity/oneim-dbagent:latest ``` -------------------------------- ### Create web.config from template (local volume) Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md This command demonstrates how to create a web.config file using a template, mounting the current directory as a volume and providing necessary environment variables for connection strings and base URLs. ```sh VERSION=latest docker run -it --rm -v $PWD:/data -e "CONNSTRING=Data Source=..." -e BASEURL=http://localhost:9999/ -e APPSERVERCONNSTRING=URL=http://localhost/AppServer oneidentity/oneim-api:linux-amd64-$VERSION --createwebcfg /data ``` -------------------------------- ### Sample Connection String Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/dbagent/README.md A sample connection string format for connecting to a MS SQL database. ```connectionstring Data Source=[Server];Initial Catalog=[DB];User ID=[User];Password=[Password] ``` -------------------------------- ### Create Web.config template on Linux Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/appserver/README.md This command demonstrates how to create a template Web.config file using the appserver container on Linux. It mounts the current directory to /data and uses the --createwebcfg argument. ```sh VERSION=latest docker run -it --rm -v $PWD:/data -e "CONNSTRING=Data Source=..." oneidentity/oneim-appserver:linux-amd64-$VERSION --createwebcfg /data ``` -------------------------------- ### Windows: Run Jobserver against Application Server Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/jobservice/README.md Runs the Jobserver for the QBMServer entry with identifier Docker42 against an application server. It maps ports, sets connection and authentication details, and mounts secrets and logs directories. ```powershell docker run -it --rm \ -p 1880:1880 \ -p 2880:2880 \ -e "DBSYSTEM=APPSERVER" \ -e "CONNSTRING=Url=https://appserver/" \ -e "AUTHSTRING=Module=DialogUser;User=[Username];Password=[Password]" \ -e "SERVERNAME=Docker42" \ -e "HTTP_USER=admin" \ -e "HTTP_PWD=fg(&R8f&Rf" \ -v C:/Path/To/secrets:C:/ProgramData/Docker/secrets:ro \ -v C:/Path/To/logs:C:/logs \ oneidentity/oneim-job:latest ``` -------------------------------- ### Windows: Run Jobserver against Microsoft SQL Server Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/jobservice/README.md Runs the Jobserver for the QBMServer entry with identifier DockerServer1 against a Microsoft SQL Server database. It maps ports, sets connection and server details, and mounts secrets and logs directories. ```powershell docker run -it --rm \ -p 1880:1880 \ -p 2880:2880 \ -e "CONNSTRING=Data Source=[Server];Initial Catalog=[DB];User ID=[User];Password=[Password]" \ -e "SERVERNAME=DockerServer1" \ -e "HTTP_USER=admin" \ -e "HTTP_PWD=fg(&R8f&Rf" \ -v C:/Path/To/secrets:C:/ProgramData/Docker/secrets:ro \ -v C:/Path/To/logs:C:/logs \ oneidentity/oneim-job:latest ``` -------------------------------- ### Linux: Run Jobserver against Application Server Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/jobservice/README.md Runs the Jobserver for the QBMServer entry with identifier Docker42 against an application server on Linux. It maps ports, sets connection and authentication details, and mounts secrets and logs directories. ```sh docker run -it --rm \ -p 1880:1880 \ -e "DBSYSTEM=APPSERVER" \ -e "CONNSTRING=Url=https://appserver/" \ -e "AUTHSTRING=Module=DialogUser;User=[Username];Password=[Password]" \ -e "SERVERNAME=Docker42" \ -e "HTTP_USER=admin" \ -e "HTTP_PWD=fg(&R8f&Rf" \ -v $PWD/secrets:/run/secrets:ro \ -v $PWD/logs:/var/log/jobservice \ oneidentity/oneim-job:latest ``` -------------------------------- ### APPSERVER Connection String Sample Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/jobservice/README.md Sample connection string for connecting using an application server. ```connectionstring Url=https://servername/ ``` -------------------------------- ### Linux: Run Jobserver against Microsoft SQL Server Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/jobservice/README.md Runs the Jobserver for the QBMServer entry with identifier DockerServer1 against a Microsoft SQL Server database on Linux. It maps ports, sets connection and server details, and mounts secrets and logs directories using Linux paths. ```sh docker run -it --rm \ -p 1880:1880 \ -e "CONNSTRING=Data Source=[Server];Initial Catalog=[DB];User ID=[User];Password=[Password]" \ -e "SERVERNAME=DockerServer1" \ -e "HTTP_USER=admin" \ -e "HTTP_PWD=fg(&R8f&Rf" \ -v $PWD/secrets:/run/secrets:ro \ -v $PWD/logs:/var/log/jobservice \ oneidentity/oneim-job:latest ``` -------------------------------- ### Create Web.config with environment variables Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md This PowerShell command demonstrates how to create a Web.config file for the One Identity Manager API server container, using environment variables for configuration. ```powershell $P = $PWD.Path.Replace("\", "/") $VERSION = "latest" docker run -it --rm \ -v $P:C:/Data \ -e "CONNSTRING=Data Source=..." \ -e "UPDATEPWD=..." \ -e BASEURL=http://localhost:9999/ \ -e APPSERVERCONNSTRING=URL=http://localhost/AppServer \ oneidentity/oneim-api:$VERSION \ --createwebcfg C:\data ``` -------------------------------- ### Create web.config from template (secrets volume) Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md This command shows how to generate a web.config file by mounting a local 'secrets' directory to '/run/secrets' within the container. This allows connection strings and other sensitive information to be sourced from secrets. ```sh VERSION=latest docker run -it --rm -v $PWD/secrets:/run/secrets -e BASEURL=http://localhost:9999/ oneidentity/oneim-api:linux-amd64-$VERSION --createwebcfg /run/secrets ``` -------------------------------- ### Create appsettings.json template on Windows Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/appserver/README.md This PowerShell command generates a template appsettings.json file for the One Identity Manager Application Server container on a Windows host. It mounts a local directory for secrets and sets environment variables for database connection and password updates. ```powershell $P = $PWD.Path.Replace("\", "/") $VERSION = "latest" docker run -it --rm \ -v $P/secrets:C:/Data \ -e "CONNSTRING=Data Source=..." \ -e "UPDATEPWD=..." \ oneidentity/oneim-appserver:$VERSION ` --createwebcfg C:\data ``` -------------------------------- ### Create Session certificate on Windows using Docker Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/appserver/README.md This command shows how to create a session certificate on Windows by running the appserver container. It mounts a local 'secrets' directory to C:/Data and uses the --createcert argument. ```powershell $P = $PWD.Path.Replace("\", "/") $VERSION = "latest" docker run -it --rm -v $P/secrets:C:/Data oneidentity/oneim-appserver:$VERSION --createcert C:\Data ``` -------------------------------- ### AUTHSTRING Sample Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/jobservice/README.md Sample authentication string for connecting to an application server. ```connectionstring Module=DialogUser;User=[User name];Password=[Password] ``` -------------------------------- ### Create Session certificate on Linux using Docker Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/appserver/README.md This command demonstrates creating a session certificate on Linux using the appserver container. It mounts the current directory to /data and uses the --createcert argument. ```sh VERSION=latest docker run -it --rm -v $PWD:/data oneidentity/oneim-appserver:linux-amd64-$VERSION --createcert /data ``` -------------------------------- ### Create Session certificate on Windows using PowerShell Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/appserver/README.md This PowerShell script generates a self-signed certificate suitable for session encryption and exports it as a PFX file. ```powershell $outfile = "Path\to\SessionCertificate.pfx" $date = (Get-Date).Date.AddDays(1000) $cert = New-SelfSignedCertificate \ -KeyAlgorithm RSA \ -KeyLength 2048 \ -HashAlgorithm SHA1 \ -KeyExportPolicy Exportable \ -NotAfter $date \ -Subject "CN=Application Server" \ -Type DocumentEncryptionCert [System.IO.File]::WriteAllBytes( \ $outfile, \ $cert.Export( \ [System.Security.Cryptography.X509Certificates.X509ContentType]::Pkcs12, \ $null)) ``` -------------------------------- ### Create Session Certificate (Linux OpenSSL) Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md OpenSSL commands to create a session certificate on Linux. ```sh openssl genrsa 2048 > private.pem openssl req -x509 -sha1 -days 1000 -new -subj "/CN=API Server" -key private.pem -out public.pem openssl pkcs12 -export -in public.pem -inkey private.pem -password pass: -out config/SessionCertificate.pfx ``` -------------------------------- ### Create Session certificate on Linux using OpenSSL Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/appserver/README.md This command sequence uses OpenSSL to generate a private key, a self-signed certificate, and then combines them into a PKCS12 file for session encryption. ```sh openssl genrsa 2048 > private.pem openssl req -x509 -sha1 -days 1000 -new -subj "/CN=Application Server" -key private.pem -out public.pem openssl pkcs12 -export -in public.pem -inkey private.pem -password pass: -out config/SessionCertificate.pfx ``` -------------------------------- ### Create Web.config from secrets folder Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md This PowerShell command shows how to create a Web.config file and place it directly into the secrets folder for the One Identity Manager API server container. ```powershell $P = $PWD.Path.Replace("\", "/") $VERSION = "latest" docker run -it --rm \ -v $P/secrets:C:/ProgramData/Docker/secrets \ -e BASEURL=http://localhost:9999/ \ oneidentity/oneim-api:$VERSION \ --createwebcfg C:/ProgramData/Docker/secrets ``` -------------------------------- ### Create Session Certificate (Windows Docker) Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md Command to create a session certificate using Docker on Windows. ```powershell $P = $PWD.Path.Replace("\", "/") $VERSION = "latest" docker run -it --rm -v $P/secrets:C:/Data oneidentity/oneim-api:$VERSION --createcert C:\Data ``` -------------------------------- ### Create Session Certificate (Linux Docker) Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md Command to create a session certificate using Docker on Linux. ```sh VERSION=latest docker run -it --rm -v $PWD:/data oneidentity/oneim-api:linux-amd64-$VERSION --createcert /data ``` -------------------------------- ### Windows: Run Jobserver in background with secrets Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/jobservice/README.md Runs the Jobserver container in the background, mapping ports and mounting secrets and logs directories. Parameters are expected to be in the secrets folder. ```powershell docker run -d \ -p 1880:1880 \ -p 2880:2880 \ -v C:/Path/To/secrets:C:/ProgramData/Docker/secrets:ro \ -v C:/Path/To/logs:C:/logs \ oneidentity/oneim-job:latest ``` -------------------------------- ### Windows Docker Run Command Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/appserver/README.md Runs the application server container in the background on Windows, mounting volumes for secrets, cache, search, and logs, and mapping port 8080. ```powershell $P = $PWD.Path.Replace("\", "/") docker run -d ` -v $P/secrets:C:/ProgramData/Docker/secrets:ro ` -v $P/data/cache:C:/Cache ` -v $P/data/search:C:/Search ` -v $P/data/logs:C:/Logs ` -p 8080:8080 ` oneidentity/oneim-appserver:latest ``` -------------------------------- ### Linux Docker Run Command Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/appserver/README.md Runs the application server container in the background on Linux, mounting volumes for secrets, search, and mapping port 8080. ```sh docker run -d \ -p 8080:8080 \ -v $PWD/secrets:/run/secrets:ro \ -v $PWD/search:/var/search \ oneidentity/oneim-appserver:latest ``` -------------------------------- ### Linux: Run Jobserver in background with secrets Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/jobservice/README.md Runs the Jobserver container in the background on Linux, mapping ports and mounting secrets and logs directories. Parameters are expected to be in the secrets folder. ```sh docker run -d \ -p 1880:1880 \ -v $PWD/secrets:/run/secrets:ro \ -v $PWD/logs:/var/log/jobservice \ oneidentity/oneim-job:latest ``` -------------------------------- ### Create Session Certificate (Windows PowerShell) Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md PowerShell script to create a self-signed session certificate on Windows. ```powershell $outfile = "Path\to\SessionCertificate.pfx" $date = (Get-Date).Date.AddDays(1000) $cert = New-SelfSignedCertificate ` -KeyAlgorithm RSA ` -KeyLength 2048 ` -HashAlgorithm SHA1 ` -KeyExportPolicy Exportable ` -NotAfter $date ` -Subject "CN=API Server" ` -Type DocumentEncryptionCert [System.IO.File]::WriteAllBytes( ` $outfile, ` $cert.Export( ` [System.Security.Cryptography.X509Certificates.X509ContentType]::Pkcs12, ` $null)) ``` -------------------------------- ### OneLogin API Connection String Format Source: https://github.com/oneidentity/identitymanager.containerimages/blob/10.0/apiserver/README.md Specifies the required format for the ONELOGINAPI connection string. ```text Domain=.onelogin.com;ClientId=;ClientSecret= ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.