Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Having issue on adding ppa:ondrej/php5 #15

Closed
matriphe opened this issue Mar 7, 2015 · 13 comments · Fixed by #16
Closed

Having issue on adding ppa:ondrej/php5 #15

matriphe opened this issue Mar 7, 2015 · 13 comments · Fixed by #16

Comments

@matriphe
Copy link

matriphe commented Mar 7, 2015

I got this error when building this on add-apt-repository -y ppa:ondrej/php5. Here's the error:

gpg: keyring `/tmp/tmp07lyg_wt/secring.gpg' created
gpg: keyring `/tmp/tmp07lyg_wt/pubring.gpg' created
gpg: requesting key E5267A6C from hkp server keyserver.ubuntu.com
gpg: /tmp/tmp07lyg_wt/trustdb.gpg: trustdb created
gpg: key E5267A6C: public key "Launchpad PPA for Ond\xc5\x99ej Sur�" imported
gpg: Total number processed: 1
gpg:               imported: 1  (RSA: 1)
Exception in thread Thread-1:
Traceback (most recent call last):
  File "/usr/lib/python3.4/threading.py", line 920, in _bootstrap_inner
    self.run()
  File "/usr/lib/python3.4/threading.py", line 868, in run
    self._target(*self._args, **self._kwargs)
  File "/usr/lib/python3/dist-packages/softwareproperties/SoftwareProperties.py", line 687, in addkey_func
    func(**kwargs)
  File "/usr/lib/python3/dist-packages/softwareproperties/ppa.py", line 370, in add_key
    return apsk.add_ppa_signing_key()
  File "/usr/lib/python3/dist-packages/softwareproperties/ppa.py", line 261, in add_ppa_signing_key
    tmp_export_keyring, signing_key_fingerprint, tmp_keyring_dir):
  File "/usr/lib/python3/dist-packages/softwareproperties/ppa.py", line 210, in _verify_fingerprint
    got_fingerprints = self._get_fingerprints(keyring, keyring_dir)
  File "/usr/lib/python3/dist-packages/softwareproperties/ppa.py", line 202, in _get_fingerprints
    output = subprocess.check_output(cmd, universal_newlines=True)
  File "/usr/lib/python3.4/subprocess.py", line 605, in check_output
    output, unused_err = process.communicate(inputdata, timeout=timeout)
  File "/usr/lib/python3.4/subprocess.py", line 936, in communicate
    stdout = _eintr_retry_call(self.stdout.read)
  File "/usr/lib/python3.4/subprocess.py", line 487, in _eintr_retry_call
    return func(*args)
  File "/usr/lib/python3.4/encodings/ascii.py", line 26, in decode
    return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc5 in position 92: ordinal not in range(128)

Is this issue came from phusion/baseimage?

@matriphe
Copy link
Author

matriphe commented Mar 7, 2015

By the way, I modified the Docker file, using phusion/baseimage:0.9.16.

@matriphe
Copy link
Author

matriphe commented Mar 7, 2015

Don't know what's going on, but I change the RUN add-apt-repository -y ppa:ondrej/php5 line and it's worked.

RUN touch /etc/apt/sources.list.d/ondrej-php5.list
RUN echo "deb http://ppa.launchpad.net/ondrej/php5/ubuntu trusty main" >> /etc/apt/sources.list.d/ondrej-php5.list
RUN echo "deb-src http://ppa.launchpad.net/ondrej/php5/ubuntu trusty main" >> /etc/apt/sources.list.d/ondrej-php5.list
RUN apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 4F4EA0AAE5267A6C

Hope it's helped someone who had same issue.

@fideloper
Copy link
Owner

That's interesting, thanks!

Sorry for the huge delay in getting back to you on this :/

I can update this repo for that (I don't use this repo anymore, so I don't modify it much).

aranw added a commit to aranw/docker-nginx-php that referenced this issue Apr 16, 2015
This should fix fideloper#15 I had a similar issue and the best fix I found was to set UTF-8 as the default language 

Fixes fideloper#15
@galindro
Copy link

@fideloper please reopen this ticket. I'm having this issue with phusion/baseimage:0.9.18

@fideloper
Copy link
Owner

This is really old and for the most part unmaintained - i don’t have the
time unfortunately. I won’t be looking into the issue, but I can leave
this open if you really want.

On Tue, Jan 12, 2016 at 3:28 PM Bruno Galindro da Costa <
notifications@github.com> wrote:

@fideloper https://github.com/fideloper please reopen this ticket. I'm
having this issue with phusion/baseimage:0.9.18


Reply to this email directly or view it on GitHub
#15 (comment)
.

@galindro
Copy link

No no... I have put my comment because I was thinking that this could be important to this project. I've fixed using the @matriphe proposed solution using apt-key

@fideloper
Copy link
Owner

Sounds good!

On Wed, Jan 13, 2016 at 4:53 AM, Bruno Galindro da Costa <
notifications@github.com> wrote:

No no... I have put my comment because I was thinking that this could be
important to this project. I've fixed using the @matriphe
https://github.com/matriphe proposed solution using apt-key


Reply to this email directly or view it on GitHub
#15 (comment)
.

@natgho-reidin
Copy link

Try this;
LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php

dartb added a commit to dartb/docker-test-project that referenced this issue Oct 12, 2017
I altered LC_ALL=en_US.UTF-8 (United States English) to LC_ALL=C.UTF8 (Computer English) as recommended here (fideloper/docker-nginx-php#15).  Was receiving error message: 'ascii' codec can't decode byte 0xc5 in position 92: ordinal not in range(128).
@quanengineering
Copy link

@natgho-reidin It works. Your solution saved my day!

@mhamzas
Copy link

mhamzas commented May 11, 2018

@natgho-reidin , yes it worked. Thanks

@abhijitgujar86
Copy link

"LC_ALL=C.UTF-8 add-apt-repository ppa:ondrej/php" worked for me too , but i did not get why ?

@dev-head
Copy link

because the owner of the php ppa, while awesome of him to contribute to the eco with his stable packages, does not wish to provide the package meta data in a format that's supported by ubuntu. It's his repo, his work and of course his name and he's allowed to do whatever he wants; regardless if it helps the people who use it. we're always free to create our own and not use his packages.

devs reasoning:
oerdnj/deb.sury.org#56

@Sheridan
Copy link

RUN apt-get -y install locales
RUN locale-gen en_US.UTF-8
ENV LANG en_US.UTF-8
ENV LANGUAGE en_US:en
ENV LC_ALL en_US.UTF-8
RUN add-apt-repository -y ppa:ondrej/php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

9 participants