Skip to content

Latest commit

 

History

History

docker

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 

Microsoft Graph CLI

Docker Image Help

Quick start

Running the container

If you are using docker-compose:

$ docker-compose run -it mgc-beta sh

Otherwise use docker to run the container.

$ docker run -it --cap-add=IPC_LOCK --rm msgraph-beta-cli sh

The IPC_LOCK capability is required by the gnome-keyring-daemon process which performs token encryption.

Building an image

Ensure you have a docker engine with API access 1.39+ and BuildKit enabled. Create 2 files nuget_user.txt and nuget_token.txt and set their content to a username and a matching personal access token that has pull access to both the microsoft and microsoftgraph GitHub organizations' package registries.

To build an image in windows powershell:

$ docker build \\?\$(Get-Location) -f . -t msgraph-beta-cli --secret id=user,src=./tmp/nuget_user.txt --secret id=token,src=./tmp/nuget_token.txt

The \\?\$(Get-Location) section of the command is used to get around the 260 character limitation on windows systems that could cause issues when copying files to the docker context. This issue impacts buildkit builds. For more information, check this issue.

To build an image in linux or WSL:

$ docker build -t msgraph-beta-cli --secret id=user,src=./tmp/nuget_user.txt --secret id=token,src=./tmp/nuget_token.txt .