Comments (8)
Interesting, cake --info
and Cake --info
works though. x
would indicate execute bit is there.
What does your your docker file look like? Or how are you launching the container?
from docker.
From WSL, via docker run --rm -it cakebuild/cake:v0.32.1-2.1-sdk
.
From Azure Pipelines, via Cake.Dungeon/azure-pipelines.yml#L10, in which I may be missing something as that build is my very first attempt to build with a Docker container on Azure Pipelines.
cake --info
and Cake --info
do work when I run them inside the container.
Note however that the executable bit is missing (for group and others) from /cake/Cake
, as I showed above:
root@aab27beb84ed:/src# ls -al /cake/Cake
-rwxrw-rw- 1 root root 97416 Jan 4 20:42 /cake/Cake
from docker.
Bit is there for the executing user though
Container only has root user.
Other wise neither cake --info
nor Cake -info
should work.
With the yaml you link to I would assume the bash build step runs on the VM and not the container.
In general without a Docker file you can only run one command with docker run, a workaround would be something like docker run --rm -it cakebuild/cake:v0.32.1-2.1-sdk /bin/bash -c "cake --botstrap && cake"
A yaml step in Azure Pipelines could look something like
- task: Docker@1
displayName: 'Run an image'
inputs:
containerregistrytype: 'Container Registry'
command: 'Run an image'
imageName: 'cakebuild/cake:v0.32.1-2.1-sdk'
volumes: '$(Build.Repository.LocalPath):/repository'
workingDirectory: /repository
containerCommand: '/bin/bash -c "cake --botstrap && cake"'
runInBackground: false
you could also have a Dockerfile in repo
Then step would look something like
- task: Docker@1
displayName: 'Build image'
And a Dockerfile could look something like
FROM cakebuild/cake:v0.32.1-2.1-sdk AS builder
ADD . /src
WORKDIR src
RUN Cake --bootstrap && Cake
from docker.
I suspect it's to do with how Azure Pipelines runs the build steps. They add a user to the container, and according to Container jobs requirements, they "will docker exec
a series of commands which expect to be run by a shell"; so you can have many build steps and each is run separately via docker exec
.
from docker.
Ok I see, I've merged your PR, if I compiles CI should have a new container out in a couple minutes.
from docker.
A new v0.32.1-2.1-sdk
is now on docker hub.
from docker.
Success! 😃
from docker.
Excellent 👍
from docker.
Related Issues (20)
- NuGetRestore Fail with error
- Bitrise image started failing HOT 1
- Add .NET Core 3 images.
- Update to latest version of Cake
- Merge Docker image into main Cake repo HOT 3
- Add Support for the .NET 6.0 SDK
- Update to Cake 2.0
- Remove 2.0 RC
- Schedule hosted builds
- Schedule self-hosted builds
- Update .NET SDK to 6.0.102
- Update .NET SDK to 6.0.201
- Improve GitHub Action workflow naming
- Update .NET SDK to 6.0.301
- Update .NET SDK to 6.0.400
- Stop building unsupported .NET 5 Images
- Start building .NET 7 images
- Build with Cake 4.0.0 and .NET 8
- Update polly to 8.2.0
- Update README with supported container tags
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from docker.