W:无法获取http://httpredir.debian.org/debian/dists/jessie-updates/main/binary-amd64/Package 404未找到

Cod*_*ein 6 debian bitbucket apt-get bitbucket-pipelines debian-jessie

我的Bitbucket管道的[相关部分]如下所示:

  - step:
      image: python:3.5.1
      name: upload to s3
      script:
        - export S3_BUCKET="elasticbeanstalk-us-east-1-122232355432"
        - export VERSION_LABEL=$(cat VERSION_LABEL)
        - apt-get update # required to install zip
        - apt-get install -y zip # required for packaging up the application
        - pip install boto3==1.3.0 # required for upload_to_s3.py
        - zip --exclude=*.git* -r /tmp/artifact.zip . # package up the application for deployment
        - python upload_to_s3.py # run the deployment script
Run Code Online (Sandbox Code Playgroud)

但是,当我在Bitbucket中运行它时,出现以下错误

+ apt-get update
Get:1 http://security.debian.org jessie/updates InRelease [44.9 kB]
Ign http://httpredir.debian.org jessie InRelease
Ign http://httpredir.debian.org jessie-updates InRelease
Get:2 http://httpredir.debian.org jessie Release.gpg [2420 B]
Ign http://httpredir.debian.org jessie-updates Release.gpg
Get:3 http://httpredir.debian.org jessie Release [148 kB]
Ign http://httpredir.debian.org jessie-updates Release
Err http://httpredir.debian.org jessie-updates/main amd64 Packages

Err http://httpredir.debian.org jessie-updates/main amd64 Packages

Err http://httpredir.debian.org jessie-updates/main amd64 Packages

Err http://httpredir.debian.org jessie-updates/main amd64 Packages

Err http://httpredir.debian.org jessie-updates/main amd64 Packages
  404  Not Found
Get:4 http://security.debian.org jessie/updates/main amd64 Packages [824 kB]
Get:5 http://httpredir.debian.org jessie/main amd64 Packages [9098 kB]
Fetched 10.1 MB in 7s (1394 kB/s)
W: Failed to fetch http://httpredir.debian.org/debian/dists/jessie-updates/main/binary-amd64/Packages  404  Not Found
E: Some index files failed to download. They have been ignored, or old ones used instead.
Run Code Online (Sandbox Code Playgroud)

看来我使用的图像不再好了,也许是吗?如何解决此问题,或者至少找到另一个包含我所需的“图像”?我最初是从Bitbucket文档示例中复制了该管道,所以我不知道如何查找和替换有效的图像。

另外,我是否可以通过某种方式在本地进行测试,所以我不必每次都要进行测试就提交/推送?

小智 8

我今天也遇到了同样的问题

通过将Docker映像版本从python:3.5.1更新到python:3.5.7或python:3.7.2来解决

参考:https : //community.atlassian.com/t5/Bitbucket-Pipelines-articles/Bitbucket-Pipelines-Apt-get-update-returning-404/ba-p/1042290#M54