diff --git a/README.md b/README.md index 5275cc8231a..f3d491cbbcb 100644 --- a/README.md +++ b/README.md @@ -6,7 +6,6 @@ Latest builds: | ------- | ------- | -------- | | azd | ![azd version](https://img.shields.io/endpoint?url=https%3A%2F%2Fazuresdkreleasepreview.blob.core.windows.net%2Fazd%2Fstandalone%2Flatest%2Fshield.json) | [Windows](https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/latest/azd-windows-amd64.zip) | [Linux](https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/latest/azd-linux-amd64.tar.gz) | [Mac](https://azuresdkreleasepreview.blob.core.windows.net/azd/standalone/latest/azd-darwin-amd64.zip) | | vscode extension | ![vscode extension version](https://img.shields.io/endpoint?url=https%3A%2F%2Fazuresdkreleasepreview.blob.core.windows.net%2Fazd%2Fvscode%2Flatest%2Fshield.json) | [VSIX](https://marketplace.visualstudio.com/items?itemName=ms-azuretools.azure-dev) | -| docker image | ![azd version](https://img.shields.io/endpoint?url=https%3A%2F%2Fazuresdkreleasepreview.blob.core.windows.net%2Fazd%2Fstandalone%2Flatest%2Fshield.json) | [`mcr.microsoft.com/azure-dev-cli-apps:latest`](https://mcr.microsoft.com/en-us/product/azure-dev-cli-apps/about) The Azure Developer CLI (`azd`) is a developer-centric command-line interface (CLI) tool for creating Azure applications. The goals of the CLI are to: diff --git a/cli/Dockerfile b/cli/Dockerfile deleted file mode 100644 index 4df264d8a8d..00000000000 --- a/cli/Dockerfile +++ /dev/null @@ -1,62 +0,0 @@ -FROM --platform=amd64 mcr.microsoft.com/dotnet/sdk:8.0 - -WORKDIR /app - -RUN export DEBIAN_FRONTEND=noninteractive \ - && wget -q https://packages.microsoft.com/config/ubuntu/20.04/packages-microsoft-prod.deb && dpkg -i packages-microsoft-prod.deb \ - && apt-get update && apt-get install -y --no-install-recommends apt-utils && apt-get install -y apt-transport-https ca-certificates curl gnupg unzip procps gnupg2 software-properties-common lsb-release \ - # functions core tools - && curl https://packages.microsoft.com/keys/microsoft.asc | gpg --dearmor > microsoft.gpg \ - && mv microsoft.gpg /etc/apt/trusted.gpg.d/microsoft.gpg \ - && sh -c 'echo "deb [arch=amd64] https://packages.microsoft.com/debian/$(lsb_release -rs | cut -d'.' -f 1)/prod $(lsb_release -cs) main" > /etc/apt/sources.list.d/dotnetdev.list' \ - && apt-get update && apt-get install -y azure-functions-core-tools-4 \ - # docker - && curl -fsSL https://download.docker.com/linux/debian/gpg | apt-key add - \ - && add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/debian $(lsb_release -cs) stable" \ - && apt-get update && apt-get install -y docker-ce-cli \ - # az cli - && curl -sSL https://aka.ms/InstallAzureCLIDeb | bash \ - # nodejs - && mkdir -p /etc/apt/keyrings \ - && curl -fsSL https://deb.nodesource.com/gpgkey/nodesource-repo.gpg.key | gpg --dearmor -o /etc/apt/keyrings/nodesource.gpg \ - && echo "deb [signed-by=/etc/apt/keyrings/nodesource.gpg] https://deb.nodesource.com/node_18.x nodistro main" | tee /etc/apt/sources.list.d/nodesource.list \ - && apt-get update \ - && apt-get install -y nodejs \ - # python - && apt-get install -y --no-install-recommends python3-pip python3-venv \ - && echo 'alias python=python3' >> ~/.bashrc \ - && echo 'alias pip=pip3' >> ~/.bashrc \ - # java - && apt-get update && apt-get install -y msopenjdk-17 \ - # terraform cli - && apt-get update && apt-get install -y software-properties-common \ - && wget -O- https://apt.releases.hashicorp.com/gpg | \ - gpg --dearmor | \ - tee /usr/share/keyrings/hashicorp-archive-keyring.gpg \ - && echo "deb [signed-by=/usr/share/keyrings/hashicorp-archive-keyring.gpg] \ - https://apt.releases.hashicorp.com $(lsb_release -cs) main" | \ - tee /etc/apt/sources.list.d/hashicorp.list \ - && apt update && apt-get install terraform \ - # kubectl CLI - && curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl" \ - && curl -LO "https://dl.k8s.io/release/$(curl -L -s https://dl.k8s.io/release/stable.txt)/bin/linux/amd64/kubectl.sha256" \ - && echo "$(cat kubectl.sha256) kubectl" | sha256sum --check \ - && install -o root -g root -m 0755 kubectl /usr/local/bin/kubectl \ - && kubectl version --client \ - && kubectl version --client --output=yaml \ - # Helm CLI - && curl -fsSL -o get_helm.sh https://raw.githubusercontent.com/helm/helm/main/scripts/get-helm-3 \ - && chmod 700 get_helm.sh \ - && ./get_helm.sh \ - # Kustomize CLI - && curl -s "https://raw.githubusercontent.com/kubernetes-sigs/kustomize/master/hack/install_kustomize.sh" | bash -s -- /usr/local/bin \ - # Kubelogin CLI - && az aks install-cli \ - # xdg-open - && apt update && apt-get install -y xdg-utils \ - # Cleanup - && apt-get clean -y && rm -rf /var/lib/apt/lists/* - -# azd -COPY cli/bin/azd-linux-amd64 /usr/bin/azd -COPY NOTICE.txt . \ No newline at end of file diff --git a/eng/pipelines/build-notice.yml b/eng/pipelines/build-notice.yml index 9d3f08d98f4..a8417e5a4f2 100644 --- a/eng/pipelines/build-notice.yml +++ b/eng/pipelines/build-notice.yml @@ -115,32 +115,6 @@ jobs: - task: ComponentGovernanceComponentDetection@0 - - job: BuildScanContainer - dependsOn: BuildCli - pool: - name: azsdk-pool-mms-ubuntu-2004-general - OSVmImage: MMSUbuntu20.04 - - variables: - ContainerName: azure-dev:cg-scan - - steps: - - checkout: self - - task: DownloadPipelineArtifact@2 - inputs: - artifact: azd-linux-amd64 - path: cli/bin - - - bash: | - docker build . -t $(ContainerName) -f cli/Dockerfile - displayName: Build container - - - task: ComponentGovernanceComponentDetection@0 - inputs: - dockerImagesToScan: $(ContainerName) - - - task: ComponentGovernanceComponentDetection@0 - - job: GenerateNoticeTxt pool: name: azsdk-pool-mms-ubuntu-2004-general diff --git a/eng/pipelines/templates/stages/publish.yml b/eng/pipelines/templates/stages/publish.yml index 5fa6592696e..5446c2437f5 100644 --- a/eng/pipelines/templates/stages/publish.yml +++ b/eng/pipelines/templates/stages/publish.yml @@ -73,57 +73,6 @@ stages: UploadMsi: true PublishBrewFormula: true - - deployment: Publish_Container - dependsOn: Publish_Release - condition: >- - and( - succeeded(), - ne('true', variables['Skip.Publish']) - ) - environment: azure-dev - - pool: - name: azsdk-pool-mms-ubuntu-2004-general - image: azsdk-pool-mms-ubuntu-2004-1espt - os: linux - - templateContext: - inputs: - - input: checkout - repository: self - - - strategy: - runOnce: - deploy: - steps: - - task: PowerShell@2 - inputs: - pwsh: true - targetType: filePath - filePath: eng/scripts/Set-CliVersionVariable.ps1 - displayName: Set CLI_VERSION - - - pwsh: | - # Initial tag - $dockerTags = '$(CLI_VERSION)' - - $isPublishingGa = eng/scripts/Test-ShouldReleasePackageVersion.ps1 ` - -CliVersion '$(CLI_VERSION)' - - if ($isPublishingGa) { - $dockerTags += ";latest" - } - - Write-Host "Setting DockerImageTags to $dockerTags" - Write-Host "###vso[task.setvariable variable=DockerImageTags]$dockerTags" - displayName: Set DockerImageTags - - - template: /eng/pipelines/templates/steps/publish-cli-container.yml - parameters: - DockerImageTags: $(DockerImageTags) - ReleaseSyndicatedDockerContainer: true - - deployment: Publish_Choco dependsOn: Publish_Release condition: >- @@ -389,13 +338,6 @@ stages: PublishShield: false UploadMsi: true - - template: /eng/pipelines/templates/steps/publish-cli-container.yml - parameters: - DockerImageTags: daily;$(CLI_VERSION) - ReleaseSyndicatedDockerContainer: false - # Artifacts are already downloaded in publish-cli.yml - DownloadArtifacts: false - - job: Publish_For_PR condition: >- and( @@ -439,14 +381,6 @@ stages: UploadInstaller: true UploadMsi: true - - ${{ if eq(variables['Build.Repository.Name'], 'Azure/azure-dev') }}: - - template: /eng/pipelines/templates/steps/publish-cli-container.yml - parameters: - DockerImageTags: pr-$(PRNumber) - ReleaseSyndicatedDockerContainer: false - # Artifacts are already downloaded in publish-cli.yml - DownloadArtifacts: false - - pwsh: | $urlBase = "$(publish-storage-location)/azd/standalone/pr/$(PRNumber)" Write-Host "##vso[task.setvariable variable=UrlBase;isOutput=true]$urlBase" diff --git a/eng/pipelines/templates/steps/publish-cli-container.yml b/eng/pipelines/templates/steps/publish-cli-container.yml deleted file mode 100644 index 95a82602854..00000000000 --- a/eng/pipelines/templates/steps/publish-cli-container.yml +++ /dev/null @@ -1,80 +0,0 @@ -parameters: - - name: DockerImageTags - type: string - - name: ReleaseSyndicatedDockerContainer - type: boolean - default: false - - # Download artifacts if not already downloaded in a previous step - - name: DownloadArtifacts - type: boolean - default: true - - name: AcrHost - type: string - default: 'azdevcliextacr.azurecr.io' - - name: SyndicatedAcrHost - type: string - default: 'azdevmcrpublish.azurecr.io' - -steps: - - ${{ if eq('true', parameters.DownloadArtifacts) }}: - # Linux binary is not signed today so download from output artifacts - - task: DownloadPipelineArtifact@2 - inputs: - artifact: azd-linux-amd64 - # Copy the item from artifacts straight to where it will go - path: release-staging - - - bash: chmod +x release-staging/azd-linux-amd64 - displayName: Set execute bit for the mac and linux release - - - task: AzureCLI@2 - displayName: Docker Auth - inputs: - azureSubscription: azdev-publishing_rg - scriptType: pscore - scriptLocation: inlineScript - inlineScript: | - az acr login --name ${{ parameters.AcrHost}} - - if ($${{ parameters.ReleaseSyndicatedDockerContainer }}) { - az acr login --name ${{ parameters.SyndicatedAcrHost }} - } - - - pwsh: | - New-Item -ItemType Directory -Path cli/bin - Copy-Item release-staging/azd-linux-amd64 cli/bin/ - displayName: Move binary to Docker build context - - - task: 1ES.BuildContainerImage@1 - displayName: Build release container - inputs: - image: release:latest - path: $(Build.SourcesDirectory) - dockerfile: cli/Dockerfile - enableNetwork: true - useBuildKit: true - - - pwsh: | - $tags = "${{ parameters.DockerImageTags }}" -split ';' - $items = @() - foreach ($tag in $tags) { - $items += "${{ parameters.AcrHost }}/azure-dev:$tag" - } - - if ($${{ parameters.ReleaseSyndicatedDockerContainer }}) { - foreach ($tag in $tags) { - $items += "${{ parameters.SyndicatedAcrHost }}/public/azure-dev-cli-apps:$tag" - } - } - - $imageNames = $items -join ',' - Write-Host "Image Names: $imageNames" - Write-Host "##vso[task.setvariable variable=ImageNames]$imageNames" - displayName: Tag release container - - - task: 1ES.PushContainerImage@1 - displayName: Push container tags - inputs: - localImage: release:latest - remoteImage: $(ImageNames)