Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
71 changes: 36 additions & 35 deletions .azure-devops/azure-pipelines.yml
Original file line number Diff line number Diff line change
Expand Up @@ -145,38 +145,39 @@ jobs:
inputs:
subFolder: github-tests/Dockerfile/build-only

- job: test_platform_with_runcmd
displayName: Test with platform and runCmd
steps:
- script: |
docker login -u $ACR_USERNAME -p $ACR_TOKEN $(ACR_NAME).azurecr.io
displayName: 'Log in to Azure Container Registry'
env:
ACR_NAME: $(ACR_NAME)
ACR_TOKEN: $(ACR_TOKEN)
ACR_USERNAME: $(ACR_USERNAME)

- script: |
printenv | sort
env:
IMAGE_TAG: $(IMAGE_TAG)

- script: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
displayName: Set up QEMU

- script: docker buildx create --use
displayName: Set up docker buildx

- task: DevcontainersCi@0
inputs:
imageName: '$(ACR_NAME).azurecr.io/devcontainers-ci/azdo-devcontainer-build-run/test/platform-with-runcmd'
subFolder: github-tests/Dockerfile/platform-with-runcmd
platform: linux/amd64,linux/arm64
runCmd: echo $HOSTNAME && [[ $HOSTNAME == "my-host" ]]

- script: |
echo "'runCmdOutput' value: $runCmdOutput"
if [["$runCmdOutput" = *my-host*]]; then
echo "'runCmdOutput' output of test_simple job doesn't contain expected value 'my-host'"
exit 1
fi
# Temporarily commented out: https://github.com/devcontainers/ci/issues/198
# - job: test_platform_with_runcmd
# displayName: Test with platform and runCmd
# steps:
# - script: |
# docker login -u $ACR_USERNAME -p $ACR_TOKEN $(ACR_NAME).azurecr.io
# displayName: 'Log in to Azure Container Registry'
# env:
# ACR_NAME: $(ACR_NAME)
# ACR_TOKEN: $(ACR_TOKEN)
# ACR_USERNAME: $(ACR_USERNAME)

# - script: |
# printenv | sort
# env:
# IMAGE_TAG: $(IMAGE_TAG)

# - script: docker run --rm --privileged multiarch/qemu-user-static --reset -p yes
# displayName: Set up QEMU

# - script: docker buildx create --use
# displayName: Set up docker buildx

# - task: DevcontainersCi@0
# inputs:
# imageName: '$(ACR_NAME).azurecr.io/devcontainers-ci/azdo-devcontainer-build-run/test/platform-with-runcmd'
# subFolder: github-tests/Dockerfile/platform-with-runcmd
# platform: linux/amd64,linux/arm64
# runCmd: echo $HOSTNAME && [[ $HOSTNAME == "my-host" ]]

# - script: |
# echo "'runCmdOutput' value: $runCmdOutput"
# if [["$runCmdOutput" = *my-host*]]; then
# echo "'runCmdOutput' output of test_simple job doesn't contain expected value 'my-host'"
# exit 1
# fi
2 changes: 1 addition & 1 deletion .devcontainer/devcontainer.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,6 @@
}
},
"features": {
"github-cli": "latest"
"ghcr.io/devcontainers/features/github-cli:1": "latest"
}
}
1 change: 0 additions & 1 deletion .github/workflows/ci_branch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,4 +27,3 @@ jobs:
runFullTests: ${{ github.event.inputs.runFullTests == 'true' }}
secrets:
AZDO_TOKEN: ${{ secrets.AZDO_TOKEN }}
MARKETPLACE_TOKEN: ${{ secrets.MARKETPLACE_TOKEN }}
7 changes: 0 additions & 7 deletions .github/workflows/ci_common.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,9 +49,6 @@ on:
AZDO_TOKEN:
description: ""
required: true
MARKETPLACE_TOKEN:
description: ""
required: true

jobs:

Expand Down Expand Up @@ -311,7 +308,6 @@ jobs:
AZDO_ORG: ${{ inputs.AZDO_ORG }}
AZDO_TOKEN: ${{ secrets.AZDO_TOKEN }}
AZURE_DEVOPS_EXT_PAT: ${{ secrets.AZDO_TOKEN }}
MARKETPLACE_TOKEN: ${{ secrets.MARKETPLACE_TOKEN }}
BUILD_NUMBER: ${{ github.run_id }}
IS_PR: ${{ github.head_ref }}
BRANCH: ${{ github.ref }}
Expand All @@ -330,7 +326,6 @@ jobs:
AZDO_ORG
AZDO_PROJECT
AZDO_BUILD
MARKETPLACE_TOKEN

#
# Jobs to test
Expand Down Expand Up @@ -391,7 +386,6 @@ jobs:
AZDO_ORG: ${{ inputs.AZDO_ORG }}
AZDO_TOKEN: ${{ secrets.AZDO_TOKEN }}
AZURE_DEVOPS_EXT_PAT: ${{ secrets.AZDO_TOKEN }}
MARKETPLACE_TOKEN: ${{ secrets.MARKETPLACE_TOKEN }}
BUILD_NUMBER: ${{ github.run_id }}
IS_PR: ${{ github.head_ref }}
BRANCH: ${{ github.ref }}
Expand All @@ -412,7 +406,6 @@ jobs:
AZDO_ORG
AZDO_PROJECT
AZDO_BUILD
MARKETPLACE_TOKEN


test-simple:
Expand Down
1 change: 0 additions & 1 deletion .github/workflows/ci_main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,3 @@ jobs:
release: true
secrets:
AZDO_TOKEN: ${{ secrets.AZDO_TOKEN }}
MARKETPLACE_TOKEN: ${{ secrets.MARKETPLACE_TOKEN }}
1 change: 0 additions & 1 deletion .github/workflows/pr-bot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,3 @@ jobs:
release: false
secrets:
AZDO_TOKEN: ${{ secrets.AZDO_TOKEN }}
MARKETPLACE_TOKEN: ${{ secrets.MARKETPLACE_TOKEN }}
1 change: 0 additions & 1 deletion .github/workflows/pr_auto.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,3 @@ jobs:
runFullTests: false
secrets:
AZDO_TOKEN: ${{ secrets.AZDO_TOKEN }}
MARKETPLACE_TOKEN: ${{ secrets.MARKETPLACE_TOKEN }}
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
// Update the VARIANT arg to pick a version of Go: 1, 1.18, 1.17
// Append -bullseye or -buster to pin to an OS version.
// Use -bullseye variants on local arm64/Apple Silicon.
"VARIANT": "1.17-bullseye",
"VARIANT": "1.18-bullseye",
// Options
"NODE_VERSION": "none"
},
Expand Down Expand Up @@ -37,6 +37,6 @@
// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "vscode",
"features": {
"docker-from-docker": "20.10"
"ghcr.io/devcontainers/features/docker-outside-of-docker:1": {"version": "20.10"}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,6 @@
// Comment out to connect as root instead. More info: https://aka.ms/vscode-remote/containers/non-root.
"remoteUser": "node",
"features": {
"golang": "1.18"
"ghcr.io/devcontainers/features/go:1": {"version":"1.18"}
}
}
6 changes: 3 additions & 3 deletions scripts/publish-azdo-task.sh
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@ set -e

script_dir="$( cd "$( dirname "${BASH_SOURCE[0]}" )" >/dev/null 2>&1 && pwd )"

if [[ -z "$MARKETPLACE_TOKEN" ]]; then
echo "MARKETPLACE_TOKEN must be specified"
if [[ -z "$AZDO_TOKEN" ]]; then
echo "AZDO_TOKEN must be specified"
exit 1
fi

cd "$script_dir/.."
echo "Publishing extension..."
vsix_file=$(ls output/devcontainers.*.vsix)
echo "Using VSIX_FILE=$vsix_file"
tfx extension publish --token $MARKETPLACE_TOKEN --vsix $vsix_file --override "{\"public\": true}"
tfx extension publish --token $AZDO_TOKEN --vsix $vsix_file --override "{\"public\": true}"
6 changes: 1 addition & 5 deletions scripts/test-azdo.sh
Original file line number Diff line number Diff line change
Expand Up @@ -7,18 +7,14 @@ if [[ -z "$AZDO_TOKEN" ]]; then
echo "AZDO_TOKEN must be specified"
exit 1
fi
if [[ -z "$MARKETPLACE_TOKEN" ]]; then
echo "MARKETPLACE_TOKEN must be specified"
exit 1
fi

cd "$script_dir/.."
vsix_file=$(ls output/devcontainers-dev.*.vsix)
echo "Using VSIX_FILE=$vsix_file"

# Publish as non-public and as devcontainers-dev
echo "Publishing private extension version..."
tfx extension publish --token "$MARKETPLACE_TOKEN" --vsix "$vsix_file" --override "{\"public\": false, \"publisher\": \"devcontainers-dev\"}" --share-with devcontainers-ci,stuartle
tfx extension publish --token "$AZDO_TOKEN" --vsix "$vsix_file" --override "{\"public\": false, \"publisher\": \"devcontainers-dev\"}" --share-with monacotools

echo "Installing private extension"
tfx extension install --token "$AZDO_TOKEN" --vsix "$vsix_file" --service-url "$AZDO_ORG"
Expand Down