Skip to content

Instantly share code, notes, and snippets.

@pjmagee
Created October 6, 2024 19:26
Show Gist options
  • Save pjmagee/4c6bcd7d2fc1d390c752278843cfbdf9 to your computer and use it in GitHub Desktop.
Save pjmagee/4c6bcd7d2fc1d390c752278843cfbdf9 to your computer and use it in GitHub Desktop.
dagger run pwsh init.ps1
echo "Initializing the GraphQL schema..."
$authHeader = [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes("${env:DAGGER_SESSION_TOKEN}:"))
dotnet graphql init `
--headers "content-type=application/json" `
--headers "Authorization=Basic $authHeader" `
--clientName DaggerClient `
"http://127.0.0.1:${env:DAGGER_SESSION_PORT}/query"
echo "Updating the GraphQL schema..."
$authHeader = [Convert]::ToBase64String([Text.Encoding]::ASCII.GetBytes("${env:DAGGER_SESSION_TOKEN}:"))
dotnet graphql update `
--headers "content-type=application/json" `
--headers "Authorization=Basic $authHeader" `
-u "http://127.0.0.1:${env:DAGGER_SESSION_PORT}/query"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment