Questions tagged [python]

Python is a dynamically and strongly typed programming language that encourages readability.

Filter by
Sorted by
Tagged with
0
votes
1answer
14 views

Passing the list of values to a python script as arguments inside ansible script

I have a python script inside ansible playbook: --- - hosts: localhost become: yes become_method: sudo become_user: root gather_facts: false tasks: - name: execute script ...
0
votes
0answers
17 views

Add body to a cloud scheduler request using the Python API

I'm extending off of this question: https://stackoverflow.com/questions/60681672/how-to-create-a-job-with-google-cloud-scheduler-python-api I'm wondering how I can insert a body object to be passed ...
0
votes
1answer
35 views

certbot installation on CentOS 8 fails

Trying to install certbot on CentOS 8 with sudo dnf install certbot python3-certbot-nginx, as suggested at certbot's website fails with the following error Error: Problem 1: package python3-certbot-...
1
vote
0answers
17 views

AWS EC2 Ubuntu instance stops executing with swap memory [closed]

I'm running a t2.micro AWS EC2 instance with Ubuntu 18 preinstalled. This has 1GB RAM memory. I'm running a program that requires 1.4GB memory. So I added 2GB of swap memory using sudo bash -c "echo '...
0
votes
0answers
11 views

Local server execution error [closed]

Code ''' from future import absolute_import from future import unicode_literals import os import subprocess import sys from bootstrapping import bootstrapping from googlecloudsdk.api_lib.app import ...
0
votes
0answers
26 views

FreeIPA on RPi3 Kerberos5 timeout

I pulled a magic trick from a hat. I put Kerberos 5 using FreeIPA on a Raspberry Pi 3 B. It's an inexpensive box that does one thing only, issuing tickets. I modified the 60 second timeout to 2000 ...
1
vote
1answer
22 views

How to use IPTables to keep a running total of the amount of data passed to and from a single IP?

I need to keep a running total of the number of bytes passed between my server and a remote server (port unspecific). I would like to keep this running total written in a file. I'm a bit new to ...
0
votes
1answer
84 views

Ubuntu 18.04 to 20.04 - Unresolved issue occured while calculating upgrade [closed]

I'm trying to upgrade my ubuntu distro from 18.04 lts to 20.04 lts and I get this error message while it's calculating data, An unresolvable problem occurred while calculating the upgrade. ...
0
votes
1answer
13 views

how can I ask pip (python package installer) to use different proxy servers for different urls?

I am currently in the following situation: my company has a proxy server for all external sites, but all internal hosts are direct connect only. Accessing them through the proxy will result in a proxy ...
0
votes
1answer
88 views

Python pip installing grpcio kills connections to my Google Compute Instance?

I'm seeing a strange issue when I try to install the Pip package "google-cloud-datastore" where once it starts building the dependent "grcpio" wheel, all TCP (including SSH) connections to the ...
0
votes
1answer
82 views

What is the prefered method to install Python with Ansible on CentOS 8

CentOS 8 does not always come with Python pre-installed, and so Ansible will fail running on the remote machine until it's been installed. However in a classic Chicken/Egg, you can't use the Ansible ...
0
votes
0answers
12 views

ImportError: cannot import name execute_manager

I am installing Graphite on Debian 9 I am following this tutorial https://gist.github.com/xlson/1363542 Current directory root@debian:/opt/graphite/webapp/graphite# pwd /opt/graphite/webapp/...
0
votes
0answers
19 views

Unable to locate package python-django-tagging

I am trying to install graphite on debian 9 . root@debian:~# lsb_release -a No LSB modules are available. Distributor ID: Debian Description: Debian GNU/Linux 9.12 (stretch) Release: 9.12 ...
3
votes
2answers
775 views

Ubuntu 20.04 minimal: “Unable to locate package python-pip”

Launching some small VMs in GCP and thought I would give Ubuntu 20.04 LTS minimal a try. After doing an "apt update; apt upgrade" I'm able to install packages like Apache, but having zero luck with ...
0
votes
1answer
27 views

Is it possible to reconfigure Python to use my upgraded openssl without rebuilding Python entirely?

I'm running CentOS 7 and the following version of Python ... [rails@server Python-3.7.0]$ python3 --version Python 3.7.0 I recently upgraded my version of openssl ... [rails@server Python-3.7.0]$ ...
0
votes
0answers
18 views

I can't install packages using yum [Errno 5] [Errno 13] Permission denied

I cannot install git package on server. Below is the output of yum command: [root@sbybz221033 ~]# yum update git Loaded plugins: langpacks, product-id, search-disabled-repos, subscription-...
1
vote
2answers
39 views

Letting systemd service to stop later without blocking on `systemctl stop`

I have bunch of services responsible for running action consumed from the queue. I want to be able to restart services gently (without interrupting action which're already running) It can be solved ...
0
votes
0answers
14 views

Apache with SSL and socket.io (python) is not working

I am trying to run a socket.io (python) server on a different port of my Apache web server, than the usual 443 https traffic. I realize there are many discussion about this subject already available, ...
0
votes
0answers
10 views

I am not able to use port 80 in my ubuntu openlitespeed server

Some file is running on port 80 how to find what is running on that port and how can I stop it and run my python(flask) app on that port
1
vote
3answers
163 views

AWS Cloud9 Building Docker Image Fail

I'm quite new to networking and server management so thank you in advance for your patience. Currently I am learning how to build a docker image on AWS's Cloud9. The tutorial I'm following is from ...
0
votes
0answers
21 views

How to make python run from terminal environment

I tried to run Ansible playbook with python through bash script, but I came across the bug described here https://github.com/ansible/ansible/issues/32142 (TL;DR When I run playbook with pause module ...
0
votes
1answer
9 views

Migration IredMail from one server to another with simultaneous updating (from 0.9.0 to 1.1)

I have IredMail 0.9.0 (released Dec 31, 2014) installed directly on the host and I want to migrate it to a new server with dockerized IredMail + LetsEncrypt SSL certificate + everything wrapped by ...
0
votes
0answers
45 views

How to use docker container as a proxy?

I have the following docker-compose: version: '3' services: mitmproxy: image: johnmccabe/mitmweb container_name: mitmproxy command: --cadir /ca --wiface 0.0.0.0 restart: always ...
0
votes
0answers
92 views

Internet speed test from bash/linux command line hangs

I am running this python script on a remote ubuntu server from command line for speed testing: https://github.com/sivel/speedtest-cli with: $ curl -s https://raw.githubusercontent.com/sivel/...
1
vote
0answers
29 views

Server crash (Error 500) repeatedly (running nginx + gunicorn on EC2 instance)

Okay, so I'm really confused about what's happening here. I've had my server up and running for about a month and everything was fine. The server was getting very little traffic (about 50-100 requests ...
1
vote
1answer
82 views

AWS S3 Bucket Django 3.0 User Profile Image Upload Access ERROR

INTRO I am following this guide as recommended, here is the guide's GitHub repo. I have created an AmazonS3FullAccess to it as well I am using the guide's 3rd example "Mixing public assets and ...
0
votes
1answer
52 views

How to send password with special characters from ansible to Python script?

I am invoking a python script from ansible playbook. While invoking I am passing the credentials to the python script as arguments. The password has some special characters. But in Python script, I ...
0
votes
1answer
30 views

Python Socket Not Able To Connect To Windows Server

I am using socket library in python and want to connect client (my computer) to server (AWS EC2 Windows instance). But client always give error:- "TimeoutError: [WinError 10060] connection failed ...
0
votes
0answers
28 views

Python SSL verification works with wget but fails with requests module

SSL verification works with wget but throwing SSL verification failed error for a self signed certificate with python requests module. Self-signed certficate: [root@abc ssl]# openssl x509 -in ...
0
votes
0answers
10 views

python script doesn't get killer

I ran a python script, and I did all the various kill commands including kill -9 PID. It says "No such process." And my directory keeps getting populated with output files.
0
votes
1answer
32 views

How can python's os.system([command]) bypass the history record? [closed]

I mean, how dare it? These two scripts have different record in history (at least by history command) # echo "hello" the direct command in shell will result in a record in history, however if I ...
0
votes
2answers
103 views

Invoking Python Script through Ansible Playbook and running it in background- Through Ansible Tower

Here I am trying to invoke a python script through ansible playbook. When I run the playbook containing below mentioned code, it is successfully invoking the script. But ansible script continues to ...
0
votes
1answer
39 views

ImportError: No module named svn.core Python Traceback

I am working on the Setup of the Subversion server in one of my environments using RHEL 8 Apache 2.4 Subversion 1.10.6 Python 2.7 Viewvc 1.2.1 Apache & Subversion installation has been done ...
3
votes
1answer
58 views

Which firewall port required to access python repository?

Trying to install python library from corporate Server. Due to security reason the internet is blocked and specific URL's only allowed. So would like to raise a firewall opening to install python lib ...
0
votes
0answers
83 views

flask, gunicorn (gevent), sqlalchemy (postgresql): too many connections

I created Flask WSGI-application which uses gunicorn as WSGI-server, for DB it uses PostgreSQL through Flask SQLAlchemy extension. That's all hosted on Heroku. gunicorn configuration number of ...
0
votes
1answer
65 views

502 Bad Gateway nginx/1.14.0 (Ubuntu)

Im trying to deploy django app using nginx & gunicorn but its showing error sudo nginx -t nginx: the configuration file /etc/nginx/nginx.conf syntax is ok nginx: configuration file /etc/nginx/...
0
votes
0answers
14 views

Boto3: get a region's local time

We're closing in on the point were we have a server in every AWS region. We would like to know the local time for a specific region to better monitor peak usage via command line. I'm fairly certain ...
0
votes
1answer
26 views

Is it possible to get result of an operation Speech to Text Recognition by its ID (Python)?

I'm trying to get response of successfully executed long_running_recognize request (speech_v1p1beta1) by its ID. I know how to get this job done from console by using SDK gcloud ml speech operations ...
0
votes
1answer
23 views

Control a systemd service through a web application built in python3

I have created a web app in python3 which is hosted on a apache2 web server using the wsgi module. Now one of the requirements of the web application is that it needs to restart a systemd service ...
0
votes
0answers
20 views

How Connect Webform To Ansible Or BASH/Python, To Start a Server Service

I'm a newbie with servers. My webmin service often stops after I'm done using it, so I have to SSH in to restart it. BUT that could be a security advantage. So I'd like to use an Ansible script (or ...
0
votes
0answers
21 views

Windows Management Instrumentation - How to get Server Roles and connected Services/Drives

Hello, for a work project I'm tasked with developing a python script that reads the roles from a Windows-Failover Cluster running in Windows Server 2019 Standard Eval. (If i need to provide more info,...
0
votes
0answers
8 views

python cgi + openldap x framework

Hy all I have been using python( cgi) + html5 + jquery + css3 and a lot of forms than insert/show/change a openldap base. Now I intent to change this using bootstrap to make my life easirer...80) I ...
1
vote
1answer
36 views

Python 3.7 doesn't seem to want to install (still shows 2.7.17?)

I'm trying to install Python 3.7 on my Ubuntu 18.04 server. Following these directions: https://phoenixnap.com/kb/how-to-install-python-3-ubuntu sudo apt update sudo add-apt-repository ppa:...
1
vote
0answers
18 views

Forbidden(403) permission access error on Apache2.4 on windows machine

I am running my Django app on Apache2.4.38. I have given all the necessary parameters and access to the Apache server. Still, I am receiving a 403 error when I try to access the Application URL. ...
0
votes
1answer
30 views

nginx fails while the website somehow still works

Description I have built my Django3, gunicorn, nginx, Ubuntu 18.04, Digital Ocean project based on this guide. I only had 1 problem that it does not shows the CSS and all other static files like ...
0
votes
0answers
9 views

zabbix status report generator

Hi I was looking for a excel or CSV report generator using python. The contents are CPU, Memory, disk space and load average. If we can have different options, please just throw down your answers, it'...
0
votes
1answer
16 views

Automatically application deployment with python (by creating Django website)

I am having 400 machines and all are connected to VPN network and i want to deploy an application(available on server).here challenges is how to collected all real time VPN IP and logic(code) in ...
0
votes
0answers
36 views

Running multiple instance of python systemd service simultaneously on Linux server

I am trying to run a python script concurrently as a systemd service on a Linux machine. Followed the instructions as per below link - Radtek's (https://stackoverflow.com/users/2023392/radtek) python ...
0
votes
0answers
10 views

how can configure daemon mode for wsgi on apache2.4 on Windows machine?

well recently I installed apache and mod_wsgi on a Windows 10 machine. I use a run.wsgi file as this: import sys sys.path.insert(0, 'C:/Apache24/htdocs/project/src') sys.path.append("C:/Apache24/...
0
votes
1answer
52 views

Failed to start gunicorn.service: Unit gunicorn.service not found. Ubunto 18.04

I am following this How To Set Up Django with Postgres, Nginx, and Gunicorn on Ubuntu 18.04 guide. I have created the following file .socket sudo nano /etc/systemd/system/gunicorn.socket [Unit] ...

1
2 3 4 5
31