Comments (8)
reporting back that it works as expected now. Thank you.
from create-pull-request.
Any actions or workflows that rely on binaries in the GitHub Actions tool cache will have compatibility problems when run in Alpine Linux containers. The tool cache doesn't have separate binaries for Alpine so it will install linux
platform binaries. For example, all the the official setup-*
actions such as setup-python
, setup-go
, etc., install binaries from the tool cache. So those installed binaries very likely don't work in an Alpine Linux container.
I've made a small fix to the action and now it's possible to run inside an Alpine Linux container by pre-installing the correct binaries for the action's dependencies.
This is an example workflow that installs git and Python at the start of the job. You can also bake these dependencies into your own Alpine Docker image if you prefer that. Note that git must be installed before running actions/checkout
, otherwise it will just download the source of the repository instead of cloning it.
(Outdated example workflow removed. See the latest documentation here.)
from create-pull-request.
Added to the documentation here: https://github.com/peter-evans/create-pull-request/blob/master/docs/concepts-guidelines.md#using-in-an-alpine-linux-container
Thank you for raising this issue!
from create-pull-request.
I'm using a ubuntu container, and saw the same error.
I add to fake the container to look like Alpine (https://github.com/AnySoftKeyboard/AnySoftKeyboard/blob/master/.github/workflows/packs_md_update.yml#L19) to make this work.
from create-pull-request.
@menny Thanks for reporting your use case. I'm reopening this issue because clearly the action needs to be a bit more intelligent about whether or not to install Python from the GitHub Actions tool cache.
I notice the base image for your container is Ubuntu, so I'm a bit confused why the python and pip binaries from the tool cache don't run. Perhaps it's something to do with this line.
dpkg --add-architecture i386
from create-pull-request.
Actually, the problem in this case is that there is a missing shared library. On the hosted VMs, /usr/local/lib
contains these shared libraries I think.
python: error while loading shared libraries: libpython3.8.so.1.0: cannot open shared object file: No such file or directory
##[error]Process completed with exit code 127.
It may not be possible to use Python from the GitHub Actions tool cache when running in any container. I might just need to make it a requirement that if you run the action in a container you must pre-install Python and git.
from create-pull-request.
I've released a fix that detects if the action is running in a container and assumes python3
and pip3
are on the PATH
. Documentation is updated here.
@menny This new fix now means that you don't need to fake running in alpine or create the symlinks. The base image of menny/ndk_ask:1.13.6
already installs Python 3 so it should just work.
from create-pull-request.
great! thanks!
I'll update my workflows.
from create-pull-request.
Related Issues (20)
- add a no-verify option HOT 1
- Support commenting on a PR when closing it HOT 4
- PR is geeting auto merge HOT 1
- Commit author is `web-flow`? HOT 3
- Fine-grained PATs will also work HOT 2
- Upgrade action to use node20 HOT 4
- Commit message not updated when PR is updated HOT 1
- Actions not triggering even with Custom App HOT 6
- Photo from Tajdoost
- stale info error when specified branch doesn't exist but a tag with the same name exists HOT 2
- Add no-verify option because rm -rf .git/hooks doesn't work HOT 2
- Github Action is not working HOT 1
- This isn't recognizing changes between two branches of two repos HOT 2
- using with git-crypt HOT 4
- Is it possible to fully restore all git state after the action? HOT 5
- Deep fetch results in massive download HOT 2
- Question about Repository HOT 1
- Provide a 'commit-message-body' field? HOT 3
- Failing to create PR using example HOT 1
- Base branch being commited with changes from branch HOT 1
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 create-pull-request.