13 May

Debian: There is no public key available for the following key IDs

Problem:
W: An error occurred during the signature verification. The repository is not updated and the previous index files will be used. GPG error: http://cdn-fastly.deb.debian.org/debian stretch-b
ackports InRelease: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 648ACFD622F3D138 NO_PUBKEY DCC9EFBF77E11517
W: Failed to fetch http://http.debian.net/debian/dists/stretch-backports/InRelease The following signatures couldn't be verified because the public key is not available: NO_PUBKEY 648ACFD622F3D138 NO_PUBKEY DCC9EFBF77E11517
W: Some index files failed to download. They have been ignored, or old ones used instead.

Solution:

apt-get install debian-keyring debian-archive-keyring
27 Feb

Solving “Can’t locate File/Which.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .)”

To solve this problem:

 Can't locate File/Which.pm in @INC (@INC contains: /usr/local/lib64/perl5 /usr/local/share/perl5 /usr/lib64/perl5/vendor_perl /usr/share/perl5/vendor_perl /usr/lib64/perl5 /usr/share/perl5 .) 
 BEGIN failed--compilation aborted

you just need to install perl-File-Which package:

yum install perl-File-Which
25 Jan

How to setup port forwarding in Windows

To start:

netsh interface portproxy add v4tov4 listenport=8080 listenaddress=0.0.0.0 connectport=80 connectaddress=127.0.0.1

And to remove:

netsh interface portproxy delete v4tov4 listenport=8080 listenaddress=0.0.0.0

You can also use:

netsh interface portproxy reset

or

netsh interface portproxy delete

to drop the forwarding. If you face some issue setting this up please refer to this.

04 Jun

Using Python Requests 2.2.1 with SNI

Server-Name-Indication, or SNI, is an official extension to SSL where the client tells the server what hostname it is contacting. It allows to host multiple SSL enabled website on one IP. To get SNI working with requests 2.2.1 you would need the following steps.

To install next packages:

If it works for you, that’s great.  But if doesn’t, you might want to make sure:

  • you have pyOpenSSL >= 0.13 (if you install it with apt-get or yum you need to remove that version and to reinstall it with pip)
  • you also have python-devel
  • you have libffi and libffi-devel

Once you have all these packages you should be able to use Requests which is able to talk to SNI enabled servers.

 

 

29 Apr

Amazon PHP SDK installation on Centos (via pear)

Installation of dependencies:

yum install php-channel-aws.noarch php-channel-guzzle.noarch php-symfony2-EventDispatcher.noarch

Installation of the library itself:

pear install aws/sdk

Checking:

[root@robo ~]# pear info aws/sdk
ABOUT PEAR.AMAZONWEBSERVICES.COM/SDK-2.2.1
==========================================
Release Type PEAR-style PHP-based Package
Name sdk
Channel pear.amazonwebservices.com
Summary Official PHP SDK for Amazon Web Services.
Description The AWS SDK for PHP enables PHP developers to
easily work with Amazon Web Services and build
scalable solutions with Amazon S3, Amazon
DynamoDB, Amazon Glacier, and more.
Maintainers Michael Dowling <[email protected]> (lead)
Jeremy Lindblom <[email protected]>
(developer)
Ryan Parman <[email protected]> (developer,
inactive)
Release Date 2013-03-18 17:30:25
Release Version 2.2.1 (stable)
API Version 2.2.1 (stable)
License Apache 2.0 (http://aws.amazon.com/apache2.0/)
Release Notes This release adds convenience features for the
Amazon S3 client, updates the Amazon RDS client
to use the latest API version, resolves an issue
with the Amazon EC2 client, and includes support
for additional regions and other enhancements.
Required Dependencies PHP version 5.3.3
PEAR installer version 1.4.0 or newer
Package guzzlephp.org/pear/Guzzle
Version 3.0.3 or newer
Extension curl
package.xml version 2.0
Last Modified 2013-04-16 16:10
Previous Installed - None -
Version
[root@robo ~]#

Getting list of installed files (there are a lot of them):

 pear list-files aws/sdk

Upd.
If it doesn’t work for you, try this way:

pear -D auto_discover=1 install pear.amazonwebservices.com/sdk