Sample Header Ad - 728x90

Unix & Linux Stack Exchange

Q&A for users of Linux, FreeBSD and other Unix-like operating systems

Latest Questions

4 votes
1 answers
3758 views
Wifi with WPA2-EAP MS-CHAPv2 authentication (username and password) during Debian installation
I am currently attempting to install Debian on my laptop computer. During the network configuration stage, I am prompted to "enter a passphrase for WPA/WPA2 PSK authentication". Unfortunately, I am on my school's network which requires both a username and a password, with the [MS-CHAPv2](https://en....
I am currently attempting to install Debian on my laptop computer. During the network configuration stage, I am prompted to "enter a passphrase for WPA/WPA2 PSK authentication". Unfortunately, I am on my school's network which requires both a username and a password, with the [MS-CHAPv2](https://en.wikipedia.org/wiki/Wi-Fi_Protected_Access#MS-CHAPv2) authentication protocol. What should I enter at the prompt? I have an Ubuntu computer which can connect to this network. Here are the contents of /etc/NetworkManager/system-connections/NetworkName: [ipv6] method=auto [connection] id=NetworkName uuid=3e728a68-a877-4681-bc0e-1e64b2ff6434 type=802-11-wireless [802-11-wireless-security] key-mgmt=wpa-eap auth-alg=open [802-11-wireless] ssid=NetworkName mode=infrastructure mac-address=84:A6:C8:A9:67:DA security=802-11-wireless-security [802-1x] eap=ttls; identity=username phase2-auth=mschapv2 password-flags=1 [ipv4] method=auto Curiously enough, the password I enter to connect to NetworkName doesn't appear anywhere. EDIT 2: Screenshot of network connection process (in a live-boot Ubuntu) Screenshot
Alessandro Power (305 rep)
May 25, 2015, 06:34 PM • Last activity: Aug 3, 2025, 11:03 AM
1 votes
2 answers
3630 views
Connect to a wireless network as standard user without administrator authentication Linux Mint 17.3
I'm trying to get a standard user on my laptop installed with Linux Mint 17.3 on the wireless. I can get to the internet just fine logged in with an administrator but as soon as i log in with a standard user it asks to unlock a system setting then asks for the password for the wireless again despite...
I'm trying to get a standard user on my laptop installed with Linux Mint 17.3 on the wireless. I can get to the internet just fine logged in with an administrator but as soon as i log in with a standard user it asks to unlock a system setting then asks for the password for the wireless again despite my having saved it. Since anyone that uses this laptop besides me will be using the standard account, they won't have any passwords this makes it unusable for any purposes that require an internet connection. Relevant attempts to fix: 1.Adding the standard user to the netdev group - no change 2.Adding a new/second admin account - no change 3.Looked up a tutorial on the Linux Mint site titled "Connect to a wireless network as standard user without administrator authentication" - this page was completely blank Note: It is definitely not a hardware issue.
cmattos (11 rep)
Mar 31, 2016, 05:37 PM • Last activity: Jul 18, 2025, 07:09 AM
1 votes
1 answers
12984 views
Ubuntu 18.04 netplan configuration for WPA-EAP
##Background I'm using `Ubuntu 18.04 server` (on a laptop, for development) and am trying to get my wifi configured to work with an `WPA-EAP` network. - To enable Wifi I followed the guide [Wifi on Ubuntu 18 server](https://gist.github.com/austinjp/9b968c75c3e54004be7cd7a134881d85) - I looked at the...
##Background I'm using Ubuntu 18.04 server (on a laptop, for development) and am trying to get my wifi configured to work with an WPA-EAP network. - To enable Wifi I followed the guide [Wifi on Ubuntu 18 server](https://gist.github.com/austinjp/9b968c75c3e54004be7cd7a134881d85) - I looked at the [Netplan Examples](https://netplan.io/examples) (none with WPA-EAP ) - I've read the [Netplan Full Documentation](https://github.com/CanonicalLtd/netplan/blob/master/doc/netplan.md) . I've got netplan to work with an an open network, even with a password protected network, but haven't been able to get it to work with WPA-EAP where both an identity and password are required. ##Attempted Configuration I've tried this in my /etc/netplan/config.yaml file: network: wifis: wlp1s0: dhcp4: yes access-points: "My-Enterprise-Network": auth: key-management: eap identity: johndoe1 password: pass1234 But when I run netplan apply I get: Error in network definition /etc/netplan/config.yaml: unknown key auth ##From the Documentation From the [online netplan documentation](https://github.com/CanonicalLtd/netplan/blob/master/doc/netplan.md) : The `auth` block supports the following properties: `key-management` (scalar) : The supported key management modes are `none` (no key management); `psk (WPA with pre-shared key, common for home wifi); eap` (WPA with EAP, common for enterprise wifi); and `802.1x` (used primarily for wired Ethernet connections). `password` (scalar) : The password string for EAP, or the pre-shared key for WPA-PSK. The following properties can be used if `key-management is eap` or `802.1x`: `method` (scalar) : The EAP method to use. The supported EAP methods are `tls` (TLS), `peap (Protected EAP), and ttls` (Tunneled TLS). `identity` (scalar) : The identity to use for EAP. ## From man netplan access-points (mapping) This provides pre-configured connections to NetworkManager. Note that users can of course select other access points/SSIDs. The keys of the mapping are the SSIDs, and the values are mappings with the following supported properties: password (scalar) Enable WPA2 authentication and set the passphrase for it. If not given, the network is assumed to be open. **Other authentication modes are not currently supported.** Note the last line: Other authentication modes are not currently supported. ###Questions 1. What's the right way to use netplan with WPA-EAP? 1. Does Ubuntu 18.04 ship with an outdated version of netplan? ( netplan --version is not supported ) Hence perhaps why the online documentation has options that the man version does not? 1. If so, can I upgrade netplan to a more cutting edge release? 1. Or does netplan need to be used with something like a wpa_supplicant.conf to specify additional parameters?
cwd (46887 rep)
Dec 18, 2018, 07:23 PM • Last activity: Jul 15, 2025, 11:03 AM
0 votes
3 answers
150 views
What are the secure ways to use credentials in bash scripts?
I have a third-party service. Its API and credentials let me scrape service data on my local Linux machine. I want to use this API inside a bash script and launch it via `cron`, but I don't want to store credentials in plain text in the script. What are the best practices for authentication?
I have a third-party service. Its API and credentials let me scrape service data on my local Linux machine. I want to use this API inside a bash script and launch it via cron, but I don't want to store credentials in plain text in the script. What are the best practices for authentication?
Aleksey (57 rep)
Jul 2, 2025, 07:39 AM • Last activity: Jul 2, 2025, 06:46 PM
2 votes
2 answers
246 views
How to achieve credential caching with run0 (as with sudo)?
`sudo` has the pleasant property of allowing one to cache credentials, i.e., if one is to execute multiple administrative commands in a row, there's less mistyping passwords. Can the same be achieved using [`run0`](https://www.freedesktop.org/software/systemd/man/devel/run0.html), `systemd-run`'s al...
sudo has the pleasant property of allowing one to cache credentials, i.e., if one is to execute multiple administrative commands in a row, there's less mistyping passwords. Can the same be achieved using [run0](https://www.freedesktop.org/software/systemd/man/devel/run0.html) , systemd-run's alternative to sudo?
Marcus Müller (47087 rep)
Jan 21, 2025, 10:41 PM • Last activity: Jun 24, 2025, 08:19 PM
1 votes
1 answers
3777 views
systemctl authenticating as other user
I have made this script that allows non-root access for a directory so a program can make changes to files in said directories. This .service has worked on a few machines and even on the same machine in the past however after a fresh reinstall of arch linux `systemd`/`systemctl` is "Authenticating a...
I have made this script that allows non-root access for a directory so a program can make changes to files in said directories. This .service has worked on a few machines and even on the same machine in the past however after a fresh reinstall of arch linux systemd/systemctl is "Authenticating as: mpd". The weird thing is when i use sudo to start it. It will work but using enable doesn't persist on reboot. I'm don't really know what I'm doing so i apologize I'm gonna read up on systemd after the semester.
[oddstap@Arch2019 ~]$ systemctl enable brightlight.service
==== AUTHENTICATING FOR org.freedesktop.systemd1.manage-unit-files ====
Authentication is required to manage system service or unit files.
Authenticating as: mpd
Password:
polkit-agent-helper-1: pam_authenticate failed: Authentication failure
==== AUTHENTICATION FAILED ====
Failed to enable unit: Access denied
[oddstap@Arch2019 ~]$
I'm not really sure why this is I've tried a few things like using the --user flag and then giving the exact directory. It has mixed results/ Ive also tried putting the service file in /etc/systemd/system that just does the same thing.
[oddstap@Arch2019 /usr/lib/systemd/system]$ systemctl --user enable /usr/lib/systemd/system/brightlight.service
Removed /home/oddstap/.config/systemd/user/multi-user.target.wants/brightlight.service.
Created symlink /home/oddstap/.config/systemd/user/multi-user.target.wants/brightlight.service → /usr/lib/systemd/system/brightlight.service.
[oddstap@Arch2019 /usr/lib/systemd/system]$
I've seen a similar issue I think [on Server Fault](https://serverfault.com/questions/841306/authentication-is-required-to-manage-system-services-or-units) . Here is the .service file I posted it here I'm pretty sure this is not the cause but I could be wrong. I'm gonna try to fix this but if anyone got any ideas let me know. Not having systemd enabling scripts is making my life hard.
[Unit]
Description Hopefully will be a solution for you reading.
Before nodered.service

[Service]
Type oneshot
User root
ExecStart=/bin/bash -c "/bin/chmod a+w /sys/class/backlight/intel_backlight/*"

[Install]
WantedBy=multi-user.target
mr Stap (61 rep)
Dec 2, 2019, 06:34 AM • Last activity: Jun 15, 2025, 07:06 PM
5 votes
1 answers
4259 views
SMTP Auth - SASL on Dovecot, Postfix and CentOS 6.2 (and Open-Xchange)
I am trying to get open SASL to work on CentOS 6.2. I followed this tutorial: http://wiki.centos.org/HowTos/postfix_sasl I suspect it works perfectly for CentOS 5.x so all I really need is an update for use on CentOS 6.2. I was feeling confident right up until I discovered half way through that dove...
I am trying to get open SASL to work on CentOS 6.2. I followed this tutorial: http://wiki.centos.org/HowTos/postfix_sasl I suspect it works perfectly for CentOS 5.x so all I really need is an update for use on CentOS 6.2. I was feeling confident right up until I discovered half way through that dovecot.conf goes mad with these settings. This link recommends that people running CentOS 6 use a different method. http://wiki2.dovecot.org/HowTo/PostfixAndDovecotSASL Neither of the methods outlined in these links work. Also I don't know how to get Open-Xchange to use SMTP authentication. It seems to be very poorly documented and their CE forum is not letting me post, nor is it showing much activity at all.
conners (203 rep)
May 9, 2012, 01:04 PM • Last activity: Jun 12, 2025, 12:05 AM
4 votes
1 answers
3949 views
Sendmail issues "530 Authentication required" error message when authinfo is supplied
`sender_email` - email address that does not exist, but must be used as FROM address, because receiver host rejects emails from other emails. `receiver_email` - email that is supposed to receive the sent message `local_smtp` - SMTP server that is installed on another computer in the local network an...
sender_email - email address that does not exist, but must be used as FROM address, because receiver host rejects emails from other emails. receiver_email - email that is supposed to receive the sent message local_smtp - SMTP server that is installed on another computer in the local network and forwards all received messages to external_smtp external_smtp - SMTP server that is installed on a computer in another network and rejects all emails that do not come from sender_email I have configured sendmail to send emails from sender_email and authenticate with user/password to local_smtp that is supposed to send the email message further to external_smtp that only accepts emails sent from a specific email, which is sender_email in this case. However, judging from the log files sendmail authenticates with external_smtp instead of local_smtp. I do not want to authenticate with external_smtp, because that is up to local_smtp. logfile: 10745 >> EHLO mgmt-snmp 10759 >> MAIL From: AUTH=sender_email 10759 >> This is a MIME-encapsulated message 10759 >>> 10759 >>> --t8IEdmbX010759.1442587188/mgmt-snmp 10759 >>> 10759 >>> The original message was received at Fri, 18 Sep 2015 16:39:48 +0200 10759 >>> from root@localhost 10759 >>> 10759 >>> ----- The following addresses had permanent fatal errors ----- 10759 >>> receiver_email 10759 >>> (reason: 530 authentication required) 10759 >>> I guess it has something to do with AUTH=sender_email, but I do not know how to change it. sendmail.mc: divert(-1)dnl #----------------------------------------------------------------------------- # $Sendmail: debproto.mc,v 8.14.4 2014-02-11 13:02:08 cowboy Exp $ # # Copyright (c) 1998-2010 Richard Nelson. All Rights Reserved. # # cf/debian/sendmail.mc. Generated from sendmail.mc.in by configure. # # sendmail.mc prototype config file for building Sendmail 8.14.4 # # Note: the .in file supports 8.7.6 - 9.0.0, but the generated # file is customized to the version noted above. # # This file is used to configure Sendmail for use with Debian systems. # # If you modify this file, you will have to regenerate /etc/mail/sendmail.cf # by running this file through the m4 preprocessor via one of the following: # * make (or make -C /etc/mail) # * sendmailconfig # * m4 /etc/mail/sendmail.mc > /etc/mail/sendmail.cf # The first two options are preferred as they will also update other files # that depend upon the contents of this file. # # The best documentation for this .mc file is: # /usr/share/doc/sendmail-doc/cf.README.gz # #----------------------------------------------------------------------------- divert(0)dnl # # Copyright (c) 1998-2005 Richard Nelson. All Rights Reserved. # # This file is used to configure Sendmail for use with Debian systems. # define(`_USE_ETC_MAIL_')dnl include(`/usr/share/sendmail/cf/m4/cf.m4')dnl VERSIONID(`$Id: sendmail.mc, v 8.14.4-4.1ubuntu1 2014-02-11 13:02:08 cowboy Exp $') OSTYPE(`debian')dnl DOMAIN(`debian-mta')dnl dnl # Items controlled by /etc/mail/sendmail.conf - DO NOT TOUCH HERE undefine(`confHOST_STATUS_DIRECTORY')dnl #DAEMON_HOSTSTATS= dnl # Items controlled by /etc/mail/sendmail.conf - DO NOT TOUCH HERE dnl # dnl # General defines dnl # dnl # SAFE_FILE_ENV: [undefined] If set, sendmail will do a chroot() dnl # into this directory before writing files. dnl # If *all* your user accounts are under /home then use that dnl # instead - it will prevent any writes outside of /home ! dnl # define(confSAFE_FILE_ENV', ')dnl dnl # dnl # Daemon options - restrict to servicing LOCALHOST ONLY !!! dnl # Remove `, Addr=' clauses to receive from any interface dnl # If you want to support IPv6, switch the commented/uncommentd lines dnl # FEATURE(`no_default_msa')dnl dnl DAEMON_OPTIONS(`Family=inet6, Name=MTA-v6, Port=smtp, Addr=::1')dnl DAEMON_OPTIONS(`Family=inet, Name=MTA-v4, Port=smtp')dnl dnl DAEMON_OPTIONS(`Family=inet6, Name=MSP-v6, Port=submission, M=Ea, Addr=::1')dnl DAEMON_OPTIONS(`Family=inet, Name=MSP-v4, Port=submission, M=Ea, Addr=127.0.0.1')dnl dnl # dnl # Be somewhat anal in what we allow define(`confPRIVACY_FLAGS',dnl `needmailhelo,needexpnhelo,needvrfyhelo,restrictqrun,restrictexpand,nobodyreturn,authwarnings')dnl dnl # dnl # Define connection throttling and window length define(confCONNECTION_RATE_THROTTLE', 15')dnl define(confCONNECTION_RATE_WINDOW_SIZE',10m')dnl dnl # dnl # Features dnl # dnl # use /etc/mail/local-host-names FEATURE(`use_cw_file')dnl dnl # dnl # The access db is the basis for most of sendmail's checking FEATURE(access_db', , skip')dnl dnl # dnl # The greet_pause feature stops some automail bots - but check the dnl # provided access db for details on excluding localhosts... FEATURE(greet_pause', 1000')dnl 1 seconds dnl # dnl # Delay_checks allows senderrecipient checking FEATURE(delay_checks', friend', `n')dnl dnl # dnl # If we get too many bad recipients, slow things down... define(confBAD_RCPT_THROTTLE',3')dnl dnl # dnl # Stop connections that overflow our concurrent and time connection rates FEATURE(conncontrol', nodelay', `terminate')dnl FEATURE(ratecontrol', nodelay', `terminate')dnl dnl # dnl # If you're on a dialup link, you should enable this - so sendmail dnl # will not bring up the link (it will queue mail for later) dnl define(confCON_EXPENSIVE',True')dnl dnl # dnl # Dialup/LAN connection overrides dnl # include(`/etc/mail/m4/dialup.m4')dnl include(`/etc/mail/m4/provider.m4')dnl dnl LOCAL_CONFIG dnl EXPOSED_USER(root uucp)dnl # users exempt from masquerading dnl LOCAL_USER(root)dnl dnl MASQUERADE_AS(`external_smtp')dnl dnl FEATURE(`allmasquerade')dnl dnl FEATURE(`masquerade_envelope')dnl dnl FEATURE(`nullclient', local_smtp)dnl LOCAL_CONFIG ## Custom configurations below (will be preserved) define(SMART_HOST', local_smtp')dnl define(confAUTH_MECHANISMS', EXTERNAL GSSAPI DIGEST-MD5 CRAM-MD5 LOGIN PLAIN')dnl FEATURE(authinfo', hash /etc/mail/authinfo')dnl define(RELAY_MAILER_ARGS', TCP $h 25')dnl dnl # dnl # Default Mailer setup MAILER_DEFINITIONS MAILER(`local')dnl MAILER(`smtp')dnl authinfo: AuthInfo:local_smtp "U:root" "I:my_username" "P:my_password"
Jonas (143 rep)
Sep 18, 2015, 03:21 PM • Last activity: Jun 11, 2025, 05:03 PM
74 votes
7 answers
92086 views
Can I find out which ssh key was used to access an account?
Is it possible to find out which ssh key was used to access an account? I have an account on a server that I let several (trusted!) people have access to via ssh. I'd find it useful to be able to know who logged in and when. I have root access so I can look at the logs, but there doesn't seem to be...
Is it possible to find out which ssh key was used to access an account? I have an account on a server that I let several (trusted!) people have access to via ssh. I'd find it useful to be able to know who logged in and when. I have root access so I can look at the logs, but there doesn't seem to be anything there. Is there some configuration switch that will put some way of identifying the key in the logs?
Andrew Stacey (2525 rep)
Jun 24, 2011, 04:53 PM • Last activity: Jun 2, 2025, 06:11 PM
2 votes
1 answers
3496 views
Creating MySQL database and user without password
I am building a set of bash scripts which basically prepare apache virtual hosts, git repositories and other stuff on a cloud server. So far so good, everything is working, but a big problem occurred: **MySQL database and users creation**. The current scripts use ssh with keys to authenticate to the...
I am building a set of bash scripts which basically prepare apache virtual hosts, git repositories and other stuff on a cloud server. So far so good, everything is working, but a big problem occurred: **MySQL database and users creation**. The current scripts use ssh with keys to authenticate to the cloud server and everyone from my team can execute commands. I want to keep it this way and somehow let them create new MySQL database and user without needing to login to mysql as root or any other user with high privileges, but I don't have any solution for this. **Idea #1** is to create a new mysql user without password and give it full rights (like root) but make it usable only @'localhost'. **Idea #2** is to store the password for this MySQL control user in a file and make it accessible only to the current ssh user which the other scripts use. Then the mysql login will use this stored password to login and create the database and user. I don't know which option is better and I know they are dangerous. I ask for opinion and any better ideas.
Ivan Dokov (205 rep)
May 10, 2014, 02:11 PM • Last activity: May 17, 2025, 03:04 PM
79 votes
5 answers
195831 views
Permit root to login via ssh only with key-based authentication
I have some doubts about certain ssh server configurations on `/etc/ssh/sshd_config`. I want the next behavior: 1. Public key authentication is the only way to authenticate as root (no password authentication or other) 2. Normal users can use both (password and public key authentication) If I set `P...
I have some doubts about certain ssh server configurations on /etc/ssh/sshd_config. I want the next behavior: 1. Public key authentication is the only way to authenticate as root (no password authentication or other) 2. Normal users can use both (password and public key authentication) If I set PasswordAuthentication no my first point is satisfied but not the second. There is a way to set PasswordAuthentication no only for root?
mavillan (3207 rep)
Nov 7, 2013, 11:41 PM • Last activity: Apr 29, 2025, 12:02 PM
8 votes
5 answers
12126 views
Disabling ssh password authentication does not work on my debian VPS
I have a Debian 7 VPS setup. I just enabled SSH Key authentication and disabled password authentication but the disabling did not work. When I attempt to SSH into my VPS, it prompts me for my SSH Key password which then works fine, BUT if I hit cancel, it will give me "Agent admitted faliure to sign...
I have a Debian 7 VPS setup. I just enabled SSH Key authentication and disabled password authentication but the disabling did not work. When I attempt to SSH into my VPS, it prompts me for my SSH Key password which then works fine, BUT if I hit cancel, it will give me "Agent admitted faliure to sign" Error and then it prompts me for the current users account password, I enter it in and it logs me in with my account password, even though it's disabled... Does anyone have any idea why it allows me to login with password access? Thank you I am connecting with a 4096 bit key. Here is my sshd_config: Port 22 # Use these options to restrict which interfaces/protocols sshd will bind to #ListenAddress :: #ListenAddress 0.0.0.0 Protocol 2 # HostKeys for protocol version 2 HostKey /etc/ssh/ssh_host_rsa_key HostKey /etc/ssh/ssh_host_dsa_key HostKey /etc/ssh/ssh_host_ecdsa_key #Privilege Separation is turned on for security UsePrivilegeSeparation yes # Lifetime and size of ephemeral version 1 server key KeyRegenerationInterval 3600 ServerKeyBits 768 # Logging SyslogFacility AUTH LogLevel INFO # Authentication: LoginGraceTime 120 PermitRootLogin no StrictModes yes RSAAuthentication yes PubkeyAuthentication yes #AuthorizedKeysFile %h/.ssh/authorized_keys # Don't read the user's ~/.rhosts and ~/.shosts files IgnoreRhosts yes # For this to work you will also need host keys in /etc/ssh_known_hosts RhostsRSAAuthentication no # similar for protocol version 2 HostbasedAuthentication no # Uncomment if you don't trust ~/.ssh/known_hosts for RhostsRSAAuthentication #IgnoreUserKnownHosts yes # To enable empty passwords, change to yes (NOT RECOMMENDED) PermitEmptyPasswords no # Change to yes to enable challenge-response passwords (beware issues with # some PAM modules and threads) ChallengeResponseAuthentication no # Change to no to disable tunnelled clear text passwords #PasswordAuthentication no # Kerberos options #KerberosAuthentication no #KerberosGetAFSToken no #KerberosOrLocalPasswd yes #KerberosTicketCleanup yes # GSSAPI options #GSSAPIAuthentication no #GSSAPICleanupCredentials yes X11Forwarding yes X11DisplayOffset 10 PrintMotd no PrintLastLog yes TCPKeepAlive yes #UseLogin no #GSSAPIAuthentication no #GSSAPICleanupCredentials yes X11Forwarding yes X11DisplayOffset 10 PrintMotd no PrintLastLog yes TCPKeepAlive yes #UseLogin no #MaxStartups 10:30:60 #Banner /etc/issue.net # Allow client to pass locale environment variables AcceptEnv LANG LC_* Subsystem sftp /usr/lib/openssh/sftp-server # Set this to 'yes' to enable PAM authentication, account processing, # and session processing. If this is enabled, PAM authentication will # be allowed through the ChallengeResponseAuthentication and # PasswordAuthentication. Depending on your PAM configuration, # PAM authentication via ChallengeResponseAuthentication may bypass # the setting of "PermitRootLogin without-password". # If you just want the PAM account and session checks to run without # PAM authentication, then enable this but set PasswordAuthentication # and ChallengeResponseAuthentication to 'no'. UsePAM yes
DebianVPS (81 rep)
Jul 24, 2015, 12:48 AM • Last activity: Apr 28, 2025, 08:37 AM
2 votes
1 answers
6400 views
Dockerfile | executor failed running [/bin/sh -c poetry install --no-dev]: exit code: 1
I'm new to Docker, so I am not sure how to interpret the cause of errors. "[Poetry][1] is a tool for dependency management and packaging in Python. It allows you to declare the libraries your project depends on and it will manage (install/update) them for you." `pip` is failing as I have not provide...
I'm new to Docker, so I am not sure how to interpret the cause of errors. "Poetry is a tool for dependency management and packaging in Python. It allows you to declare the libraries your project depends on and it will manage (install/update) them for you." pip is failing as I have not provided credentials. **How do I add my credentials to my url or pytest.conf file?** --- Update: I have created a pip.conf file. Now, docker build has a lot more successful installs. However, still fails. --- pip.conf (PAT censored):
[global]
extra-index-url=https://@pkgs.dev.azure.com/iotahoe/Halo/_packaging/private-sources/pypi/simple '
ls:
me@LAPTOP-G1DAPU88:~/.ssh/workers-python/workers/ontology_tagger$ ls
Dockerfile  README.md  azure-pipeline-ontology_tagger.yaml  ontology_tagger  poetry.lock  pyproject.toml  pytest.ini  wss-unified-agent.config  wss_agent.sh
pytest.ini:
[pytest]
markers =
    integration: create endpoint and test returned confidence intervals
    unit: interrogate results of most recent trained model on select inputs
testpaths = tests/
--- **Credentials Issue**
danielbellio@LAPTOP-G1DAPU88:~/.ssh/workers-python/workers/ontology_tagger$ docker build --no-cache -t my_app -f /home/danielbellio/.ssh/workers-python/workers/ontology_tagger/Dockerfile .
[+] Building 1880.1s (16/23)                                                                                                                                                                               
 => [internal] load build definition from Dockerfile                                                                                                                                                  0.0s
 => => transferring dockerfile: 38B                                                                                                                                                                   0.0s
 => [internal] load .dockerignore                                                                                                                                                                     0.0s
 => => transferring context: 2B                                                                                                                                                                       0.0s
 => [internal] load metadata for docker.io/library/python:3.7-slim                                                                                                                                    8.8s
 => [auth] library/python:pull token for registry-1.docker.io                                                                                                                                         0.0s
 => CACHED [base 1/7] FROM docker.io/library/python:3.7-slim@sha256:798c7c77f4bba96b35de5fe9832b81084dcc4c1c52806d7976bf9233c7c3c4a6                                                                  0.0s
 => [internal] load build context                                                                                                                                                                     0.1s
 => => transferring context: 2.13kB                                                                                                                                                                   0.0s
 => CACHED https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py                                                                                                                 0.0s
 => [base 2/7] RUN apt-get update -y     && apt-get -y --no-install-recommends install curl wget    && rm -rf /var/lib/apt/lists/*                                                                   14.7s
 => [base 3/7] WORKDIR /home/worker/python/ontology_tagger                                                                                                                                            0.1s 
 => [base 4/7] ADD https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py  ./                                                                                                     0.1s 
 => [base 5/7] RUN python get-poetry.py && chmod +x /etc/poetry/bin/poetry                                                                                                                           59.4s 
 => [base 6/7] RUN --mount=type=cache,target=/root/.cache pip install twine keyring artifacts-keyring                                                                                                27.8s 
 => [base 7/7] RUN --mount=type=cache,target=/root/.cache apt update && apt install gcc -y                                                                                                           60.4s 
 => [build 1/6] COPY . .                                                                                                                                                                              0.1s 
 => [build 2/6] RUN poetry config experimental.new-installer false                                                                                                                                    3.0s 
 => ERROR [build 3/6] RUN poetry install --no-dev                                                                                                                                                  1705.5s 
------                                                                                                                                                                                                     
 > [build 3/6] RUN poetry install --no-dev:                                                                                                                                                                
#16 1.980 Creating virtualenv ontology-tagger in /home/worker/python/ontology_tagger/.venv                                                                                                                 
#16 7.523 Installing dependencies from lock file                                                                                                                                                           
#16 13.64                                                                                                                                                                                                  
#16 13.64 Package operations: 199 installs, 0 updates, 1 removal                                                                                                                                           
#16 13.64 
#16 13.64   - Removing wheel (0.37.0)
#16 15.02   - Installing six (1.16.0)
#16 16.84   - Installing typing-extensions (3.10.0.0)
#16 17.93   - Installing zipp (3.5.0)
#16 19.00   - Installing certifi (2021.5.30)
#16 20.10   - Installing charset-normalizer (2.0.4)
#16 21.21   - Installing greenlet (1.1.1)
#16 23.46   - Installing idna (3.2)
#16 24.81   - Installing importlib-metadata (4.6.3)
#16 26.52   - Installing ipython-genutils (0.2.0)
#16 28.13   - Installing markupsafe (2.0.1)
#16 29.85   - Installing promise (2.3)
#16 32.66   - Installing pyasn1 (0.4.8)
#16 35.22   - Installing pycparser (2.20)
#16 36.56   - Installing pytz (2021.1)
#16 38.94   - Installing rx (1.6.1)
#16 40.94   - Installing urllib3 (1.26.6)
#16 42.25   - Installing attrs (21.2.0)
#16 43.99   - Installing cachetools (4.2.2)
#16 45.63   - Installing cffi (1.14.6)
#16 47.33   - Installing graphql-core (2.3.2)
#16 49.38   - Installing grpcio (1.39.0)
#16 58.20   - Installing heapdict (1.0.1)
#16 60.10   - Installing humanfriendly (9.2)
#16 61.95   - Installing jmespath (0.10.0)
#16 63.62   - Installing locket (0.2.1)
#16 65.39   - Installing mako (1.1.4)
#16 67.76   - Installing numpy (1.21.1)
#16 79.65   - Installing oauthlib (3.1.1)
#16 81.43   - Installing protobuf (3.17.3)
#16 84.52   - Installing pyasn1-modules (0.2.8)
#16 86.70   - Installing pyparsing (2.4.7)
#16 88.44   - Installing pyrsistent (0.18.0)
#16 90.19   - Installing python-dateutil (2.8.2)
#16 92.69   - Installing python-editor (1.0.4)
#16 95.69   - Installing pytzdata (2020.1)
#16 98.10   - Installing pyyaml (5.3.1)
#16 101.9   - Installing requests (2.26.0)
#16 103.1   - Installing rsa (4.7.2)
#16 104.7   - Installing sqlalchemy (1.4.22)
#16 109.0   - Installing toolz (0.11.1)
#16 110.9   - Installing traitlets (5.0.5)
#16 113.0   - Installing tzlocal (1.5.1)
#16 116.0   - Installing zope.event (4.5.0)
#16 117.6   - Installing zope.interface (5.4.0)
#16 120.6   - Installing alembic (1.4.1)
#16 124.2   - Installing aniso8601 (7.0.0)
#16 125.9   - Installing backports.entry-points-selectable (1.1.0)
#16 127.9   - Installing botocore (1.21.19)
#16 135.5   - Installing click (7.1.2)
#16 137.3   - Installing cloudpickle (1.6.0)
#16 138.9   - Installing coloredlogs (14.0)
#16 140.5   - Installing contextlib2 (21.6.0)
#16 142.2   - Installing croniter (1.0.15)
#16 144.1   - Installing dask (2.30.0)
#16 147.4   - Installing dill (0.3.4)
#16 149.2   - Installing distlib (0.3.2)
#16 151.5   - Installing docstring-parser (0.7.1)
#16 760.1   - Installing filelock (3.0.12)
#16 762.5   - Installing fsspec (2021.7.0)
#16 766.0   - Installing funcsigs (1.0.2)
#16 768.2   - Installing future (0.18.2)
#16 778.4   - Installing gevent (21.8.0)
#16 810.7   - Installing google-auth (1.34.0)
#16 813.7   - Installing graphql-relay (2.0.1)
#16 815.7   - Installing grpcio-health-checking (1.39.0)
#16 817.7   - Installing itsdangerous (1.1.0)
#16 821.3   - Installing jinja2 (2.11.3)
#16 824.1   - Installing jsonschema (3.2.0)
#16 826.4   - Installing jupyter-core (4.7.1)
#16 828.7   - Installing marshmallow (3.13.0)
#16 831.3   - Installing msgpack (1.0.2)
#16 834.3   - Installing multidict (5.1.0)
#16 839.0   - Installing mypy-extensions (0.4.3)
#16 841.2   - Installing packaging (20.9)
#16 843.7   - Installing pandas (1.1.4)
#16 895.7   - Installing partd (1.2.0)
#16 898.7   - Installing pendulum (1.4.4)
#16 914.4   - Installing pillow (8.3.1)
#16 947.3   - Installing platformdirs (2.2.0)
#16 949.7   - Installing psutil (5.8.0)
#16 952.9   - Installing requests-oauthlib (1.3.0)
#16 955.5   - Installing smmap (4.0.0)
#16 958.1   - Installing sortedcontainers (2.4.0)
#16 960.0   - Installing tabulate (0.8.9)
#16 962.5   - Installing tblib (1.7.0)
#16 965.8   - Installing toposort (1.6)
#16 969.3   - Installing tornado (6.1)
#16 973.7   - Installing tqdm (4.49.0)
#16 976.6   - Installing watchdog (2.1.3)
#16 979.4   - Installing webencodings (0.5.1)
#16 981.2   - Installing websocket-client (0.59.0)
#16 983.9   - Installing werkzeug (1.0.1)
#16 986.8   - Installing zict (2.0.0)
#16 989.2   - Installing absl-py (0.13.0)
#16 992.2   - Installing async-timeout (3.0.1)
#16 994.5   - Installing bleach (4.0.0)
#16 996.7   - Installing bokeh (2.3.3)
#16 1020.0   - Installing cached-property (1.5.2)
#16 1023.2   - Installing cfgv (3.3.0)
#16 1025.6   - Installing chardet (4.0.0)
#16 1028.7   - Installing colorama (0.4.4)
#16 1030.6   - Installing configparser (5.0.2)
#16 1032.8   - Installing cycler (0.10.0)
#16 1035.1   - Installing dagster (0.9.22.post0)
#16 1041.2   - Installing defusedxml (0.7.1)
#16 1043.7   - Installing distributed (2.30.1)
#16 1049.5   - Installing distro (1.6.0)
#16 1052.8   - Installing docker (5.0.0)
#16 1055.5   - Installing dockerpty (0.4.1)
#16 1059.3   - Installing docopt (0.6.2)
#16 1064.4   - Installing entrypoints (0.3)
#16 1067.1   - Installing flask (1.1.4)
#16 1069.8   - Installing gevent-websocket (0.10.1)
#16 1072.8   - Installing gitdb (4.0.7)
#16 1075.4   - Installing google-auth-oauthlib (0.4.5)
#16 1078.1   - Installing graphene (2.1.9)
#16 1081.4   - Installing graphql-server-core (1.2.0)
#16 1085.9   - Installing identify (2.2.13)
#16 1089.3   - Installing joblib (1.0.1)
#16 1092.6   - Installing kiwisolver (1.3.1)
#16 1095.8   - Installing markdown (3.3.4)
#16 1099.0   - Installing marshmallow-enum (1.5.1)
#16 1101.4   - Installing mistune (0.8.4)
#16 1104.0   - Installing multiprocess (0.70.12.2)
#16 1107.9   - Installing nbformat (5.1.3)
#16 1111.8   - Installing nodeenv (1.6.0)
#16 1114.9   - Installing pandocfilters (1.4.3)
#16 1121.0   - Installing pathspec (0.8.1)
#16 1123.2   - Installing plumbum (1.7.0)
#16 1125.3   - Installing pox (0.3.0)
#16 1127.4   - Installing ppft (1.6.6.4)
#16 1129.2   - Installing prometheus-client (0.11.0)
#16 1131.2   - Installing pydantic (1.8.2)
#16 1136.3   - Installing pygments (2.9.0)
#16 1139.9   - Installing pymongo (3.12.0)
#16 1143.5   - Installing python-dotenv (0.19.0)
#16 1145.5   - Installing pyyaml-include (1.2.post2)
#16 1147.6   - Installing regex (2020.11.13)
#16 1151.2   - Installing s3transfer (0.5.0)
#16 1153.2   - Installing stringcase (1.2.0)
#16 1157.5   - Installing tensorboard-data-server (0.6.1)
#16 1161.9   - Installing tensorboard-plugin-wit (1.8.0)
#16 1165.3   - Installing testpath (0.5.0)
#16 1167.8   - Installing texttable (1.6.4)
#16 1170.2   - Installing toml (0.10.2)
#16 1172.8   - Installing torch (1.7.1)
#16 1469.6   - Installing typing-inspect (0.7.1)
#16 1472.3   - Installing virtualenv (20.7.2)
#16 1478.0   - Installing yarl (1.6.3)
#16 1481.9   - Installing aiohttp (3.7.4.post0)
#16 1488.6   - Installing autologging (1.3.2)
#16 1491.0   - Installing boto3 (1.18.19)
#16 1495.9   - Installing copier (5.1.0)
#16 1498.8   - Installing cryptography (3.4.7)
#16 1502.4   - Installing dagster-dask (0.9.22.post0)
#16 1506.1   - Installing dagster-graphql (0.9.22.post0)
#16 1509.5   - Installing databricks-cli (0.15.0)
#16 1514.2   - Installing dataclasses-json (0.5.4)
#16 1517.4   - Installing docker-compose (1.29.2)
#16 1521.0   - Installing flask-cors (3.0.10)
#16 1523.4   - Installing flask-graphql (2.0.1)
#16 1527.9   - Installing flask-sockets (0.2.1)
#16 1530.5   - Installing gitpython (3.1.20)
#16 1533.5   - Installing google-pasta (0.2.0)
#16 1536.4   - Installing graphql-ws (0.3.1)
#16 1539.7   - Installing gunicorn (20.1.0)
#16 1543.7   - Installing huggingface-hub (0.0.2)
#16 1546.6   - Installing matplotlib (3.4.2)
#16 1557.1   - Installing minio (6.0.2)
#16 1560.1   - Installing mongoengine (0.20.0)
#16 1562.9   - Installing motor (2.5.0)
#16 1565.5   - Installing nbconvert (5.6.1)
#16 1569.7   - Installing pathos (0.2.8)
#16 1572.6   - Installing pre-commit (2.14.0)
#16 1576.3   - Installing prometheus-flask-exporter (0.18.2)
#16 1581.1   - Installing protobuf3-to-dict (0.1.5)
#16 1586.2   - Installing psycopg2-binary (2.9.1)
#16 1590.0   - Installing pyarrow (2.0.0)
#16 1603.1   - Installing querystring-parser (1.2.4)
#16 1607.8   - Installing sacremoses (0.0.45)
#16 1615.6   - Installing scipy (1.7.1)
#16 1634.3   - Installing smdebug-rulesconfig (1.0.1)
#16 1637.7   - Installing sqlparse (0.4.1)
#16 1640.8   - Installing tensorboard (2.6.0)
#16 1653.9   - Installing threadpoolctl (2.2.0)
#16 1657.0   - Installing tokenizers (0.10.3)
#16 1664.0   - Installing torchmetrics (0.3.2)
#16 1668.0   - Installing xxhash (2.0.2)
#16 1671.7   - Installing dagit (0.9.22.post0)
#16 1676.9   - Installing dagster-aws (0.9.22.post0)
#16 1680.8   - Installing dagster-pandas (0.9.22.post0)
#16 1685.5   - Installing dagster-postgres (0.9.22.post0)
#16 1689.3   - Installing datasets (1.4.1)
#16 1692.6   - Installing mlflow (1.15.0)
#16 1701.5   - Installing pwmf (0.1.3.1.dev1)
#16 1704.6 
#16 1704.6   EnvCommandError
#16 1704.6 
#16 1704.6   Command ['/home/worker/python/ontology_tagger/.venv/bin/pip', 'install', '--no-deps', '--index-url', 'https://pkgs.dev.azure.com/iotahoe/Halo/_packaging/private-sources/pypi/simple ', 'pwmf==0.1.3.1.dev1'] errored with the following return code 2, and output: 
#16 1704.6   Looking in indexes: https://pkgs.dev.azure.com/iotahoe/Halo/_packaging/private-sources/pypi/simple 
#16 1704.6   User for pkgs.dev.azure.com: ERROR: Exception:
#16 1704.6   Traceback (most recent call last):
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/cli/base_command.py", line 216, in _main
#16 1704.6       status = self.run(options, args)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/cli/req_command.py", line 182, in wrapper
#16 1704.6       return func(self, options, args)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/commands/install.py", line 325, in run
#16 1704.6       reqs, check_supported_wheels=not options.target_dir
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 183, in resolve
#16 1704.6       discovered_reqs.extend(self._resolve_one(requirement_set, req))
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 388, in _resolve_one
#16 1704.6       abstract_dist = self._get_abstract_dist_for(req_to_install)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 339, in _get_abstract_dist_for
#16 1704.6       self._populate_link(req)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 305, in _populate_link
#16 1704.6       req.link = self._find_requirement_link(req)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/resolution/legacy/resolver.py", line 270, in _find_requirement_link
#16 1704.6       best_candidate = self.finder.find_requirement(req, upgrade)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/index/package_finder.py", line 899, in find_requirement
#16 1704.6       req.name, specifier=req.specifier, hashes=hashes,
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/index/package_finder.py", line 881, in find_best_candidate
#16 1704.6       candidates = self.find_all_candidates(project_name)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/index/package_finder.py", line 826, in find_all_candidates
#16 1704.6       project_url, link_evaluator=link_evaluator,
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/index/package_finder.py", line 790, in process_project_url
#16 1704.6       html_page = self._link_collector.fetch_page(project_url)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/index/collector.py", line 643, in fetch_page
#16 1704.6       return _get_html_page(location, session=self.session)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/index/collector.py", line 455, in _get_html_page
#16 1704.6       resp = _get_html_response(url, session=session)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/index/collector.py", line 169, in _get_html_response
#16 1704.6       "Cache-Control": "max-age=0",
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_vendor/requests/sessions.py", line 543, in get
#16 1704.6       return self.request('GET', url, **kwargs)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/network/session.py", line 421, in request
#16 1704.6       return super(PipSession, self).request(method, url, *args, **kwargs)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_vendor/requests/sessions.py", line 530, in request
#16 1704.6       resp = self.send(prep, **send_kwargs)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_vendor/requests/sessions.py", line 650, in send
#16 1704.6       r = dispatch_hook('response', hooks, r, **kwargs)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_vendor/requests/hooks.py", line 31, in dispatch_hook
#16 1704.6       _hook_data = hook(hook_data, **kwargs)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/network/auth.py", line 256, in handle_401
#16 1704.6       username, password, save = self._prompt_for_password(parsed.netloc)
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/network/auth.py", line 226, in _prompt_for_password
#16 1704.6       username = ask_input("User for {}: ".format(netloc))
#16 1704.6     File "/home/worker/python/ontology_tagger/.venv/lib/python3.7/site-packages/pip/_internal/utils/misc.py", line 259, in ask_input
#16 1704.6       return input(message)
#16 1704.6   EOFError: EOF when reading a line
#16 1704.6   WARNING: You are using pip version 20.2.2; however, version 21.2.4 is available.
#16 1704.6   You should consider upgrading via the '/home/worker/python/ontology_tagger/.venv/bin/python -m pip install --upgrade pip' command.
#16 1704.6   
#16 1704.6 
#16 1704.6   at /etc/poetry/lib/poetry/utils/env.py:1074 in _run
#16 1704.8       1070│                 output = subprocess.check_output(
#16 1704.8       1071│                     cmd, stderr=subprocess.STDOUT, **kwargs
#16 1704.8       1072│                 )
#16 1704.8       1073│         except CalledProcessError as e:
#16 1704.8     → 1074│             raise EnvCommandError(e, input=input_)
#16 1704.8       1075│ 
#16 1704.8       1076│         return decode(output)
#16 1704.8       1077│ 
#16 1704.9       1078│     def execute(self, bin, *args, **kwargs):
------
executor failed running [/bin/sh -c poetry install --no-dev]: exit code: 1
Dockerfile (lines 5 to 7):
#https://github.com/moby/buildkit/blob/master/frontend/dockerfile/docs/syntax.md 
#require set DOCKER_BUILDKIT=1

FROM python:3.7-slim as base
RUN apt-get update -y \
    && apt-get -y --no-install-recommends install curl wget\
    && rm -rf /var/lib/apt/lists/* 
ENV ROOT /home/worker/python/ontology_tagger
WORKDIR $ROOT

ARG ATLASSIAN_TOKEN
ARG POETRY_HTTP_BASIC_AZURE_PASSWORD
ARG ACCESS_KEY
ENV AWS_ACCESS_KEY_ID=$ACCESS_KEY
ARG SECRET_KEY
ENV AWS_SECRET_ACCESS_KEY=$SECRET_KEY
ARG REPO
ENV REPO_URL=$REPO
# Copy/symlink pypic file to the docker context before running docker build
ENV PYPIRC_PATH=$ROOT/.pypirc

ENV \
    PYTHONFAULTHANDLER=1 \
    POETRY_VERSION=1.1.4 \
    POETRY_HOME=/etc/poetry \
    XDG_CACHE_HOME=/home/worker/.cache \
    POETRY_VIRTUALENVS_IN_PROJECT=true \
    MPLCONFIGDIR=/home/worker/matplotlib \
    PATH=/home/worker/python/ontology_tagger/.venv/bin:/usr/local/bin:/etc/poetry/bin:$PATH

# System deps:
ADD https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py  ./
RUN python get-poetry.py && chmod +x /etc/poetry/bin/poetry
# Copy only requirements to cache them in docker layer
RUN --mount=type=cache,target=/root/.cache pip install twine keyring artifacts-keyring
RUN --mount=type=cache,target=/root/.cache apt update && apt install gcc -y

FROM base as ws
ARG WS_APIKEY
ARG WS_PROJECTVERSION=
ARG WS_PROJECTNAME=workers-python-ontology_tagger
ARG WS_PRODUCTNAME=HALO
COPY --chown=worker:worker . .
RUN --mount=type=cache,uid=1000,target=/home/worker/.cache poetry install --no-dev
COPY --from=openjdk:15-slim-buster /usr/local/openjdk-15 /usr/local/openjdk-15
ENV JAVA_HOME /usr/local/openjdk-15
ENV PATH $JAVA_HOME/bin:$PATH
RUN --mount=type=cache,uid=1000,target=/home/worker/.cache ./wss_agent.sh

FROM base as test
COPY . .
RUN poetry config experimental.new-installer false
RUN poetry install
RUN cd ontology_tagger && poetry run invoke deploy
# RUN sphinx-build -b confluence -Q docs/source docs/build -E -a -D confluence_server_pass=$ATLASSIAN_TOKEN

FROM base as package
COPY . .
RUN poetry build
RUN python -m pip install --upgrade pip && \
pip install twine keyring artifacts-keyring && \
twine upload -r $REPO_URL --config-file $PYPIRC_PATH dist/* --skip-existing

FROM base as build
COPY . .
RUN poetry config experimental.new-installer false
RUN poetry install --no-dev
RUN pip3 --no-cache-dir install --upgrade awscli
RUN aws s3 cp s3://iotahoe-datascience/python_workers/dbpedia/output/ontologytagger-2021-05-23-20-49-40-099/output/model.tar.gz $ROOT/ontology_tagger
RUN mkdir $ROOT/ontology_tagger/bert-base-cased && cd $ROOT/ontology_tagger/bert-base-cased && \
wget https://huggingface.co/bert-base-cased/resolve/main/config.json  && \
wget https://huggingface.co/bert-base-cased/resolve/main/tokenizer.json  && \
wget https://huggingface.co/bert-base-cased/resolve/main/tokenizer_config.json  

FROM python:3.7-slim as production
ENV  ROOT=/home/worker/python/ontology_tagger \
     VIRTUAL_ENV=/home/worker/python/ontology_tagger/.venv\
     PATH=/home/worker/python/ontology_tagger/.venv/bin:/home/worker/python/ontology_tagger:$PATH
COPY --from=build /home/worker/python/ontology_tagger/pyproject.toml /home/worker/python/
COPY --from=build /home/worker/python/ontology_tagger/.venv /home/worker/python/ontology_tagger/.venv
COPY --from=build /home/worker/python/ontology_tagger/ontology_tagger /home/worker/python/ontology_tagger
WORKDIR $ROOT
ENV PYTHONPATH=$ROOT:/home/worker/python/
# args in format mongodb://user:pass@mongodb:27017/ops?authSource=admin,ops,jobs,pipelineId-ce6b9dad-0fa1-42f7-a04d-b54d1468dc7f:ontology_tagger_worker
ENTRYPOINT [ "primary_worker", "--mongo" ]
StressedBoi_69420 (121 rep)
Aug 23, 2021, 01:34 PM • Last activity: Apr 27, 2025, 12:03 PM
3 votes
1 answers
4930 views
VNC - Too many authentication failures
I've been trying to Google, but all of the issues refers connection from PC to remote VNC server. So. I have an issue with VNC communication from Android to Linux. I have installed a TightVNC Server on latest Ubuntu version which works fine if I connect to it from PC with RealVNC Viewer on port 5901...
I've been trying to Google, but all of the issues refers connection from PC to remote VNC server. So. I have an issue with VNC communication from Android to Linux. I have installed a TightVNC Server on latest Ubuntu version which works fine if I connect to it from PC with RealVNC Viewer on port 5901. I downloaded a VNC Viewer by RealVNC for Android and if I try to connect to my remote host it says "Too many authentication failures" even on first try. I also tried a couple different VNC Viewers, but result is exactly same. What would be the reason and how I am able to fix it? Some people were speaking about that the client can be unsecure, but I'm not sure what difference there would be with PC and Android version of VNC. - From PC to remote: Works - From Android to remote: Doesn't work About half-year ago on my different server I had no similar issues. It was working fine, no matter what device I used to connect VNC if I knew IP, port and password.
Weird E. (41 rep)
Nov 6, 2016, 03:37 AM • Last activity: Apr 26, 2025, 10:05 PM
0 votes
1 answers
172 views
fprintd times out
On login, `sudo` call, or any authentication attempt, the process hangs for a while, then prompts for password. Expected behavior: immediately display fingerprint prompt. Upon investigation, `fprintd-verify`, `fprintd-enroll`, `fprintd-delete`, and `fprintd-list` all time out with the following erro...
On login, sudo call, or any authentication attempt, the process hangs for a while, then prompts for password. Expected behavior: immediately display fingerprint prompt. Upon investigation, fprintd-verify, fprintd-enroll, fprintd-delete, and fprintd-list all time out with the following error:
$ fprintd-list $USERNAME # example command
Failed to get Fprintd manager: Error calling StartServiceByName for net.reactivated.Fprint: Timeout was reached
My fingerprint sensor is supported; fprintd, fprintd-pam, and libfprint were installed from official repositories on distro install. All are configured as default when installed, with no modificatons. Running Fedora 42. This behavior was not present a week ago, when I used fprintd-enroll right-middle-finger to register a fingerprint. It developed sometime after a system upgrade from Fedora 41 to 42.
Akhil Pillai (1 rep)
Apr 23, 2025, 05:37 PM • Last activity: Apr 25, 2025, 01:51 AM
0 votes
1 answers
3872 views
LDAP server setup with GUI on CentOS7
I have, in the past, set up an LDAP server using OpenSuSE (13.2), which worked well since there was a YaST module which allowed a GUI set-up. Now I have the problem that I must set up an OpenLDAP server on a small department cluster running CentOS 7, which apparently does not have a GUI/TUI for such...
I have, in the past, set up an LDAP server using OpenSuSE (13.2), which worked well since there was a YaST module which allowed a GUI set-up. Now I have the problem that I must set up an OpenLDAP server on a small department cluster running CentOS 7, which apparently does not have a GUI/TUI for such purposes. Since I am not experienced with the LDIF-based set-up and I fully expect that the maintenance of the cluster is going to be dropped on a different PhD student when I'm gone I want to be able to configure the LDAP server using some sort of GUI. To date I have tried Webmin, which was a total fiasco. It appears to set up the basic configuration of the server OK (at least slapd starts), but If I try to run any query against the DB the response is Search failed: No such object, even for the base DN. If I attempt to add a tree (i.e. an organisational unit) using said interface the result is an error stating that Webmin could not find a suitable object class for the new DN. Therefore I'm giving up on this piece of software. *My question is thus:* Is there a free tool which would allow one to configure an LDAP server in CentOS without having to write the entire configuration by hand? Here I am looking specifically for tools which are **not** web-based (so not phpLDAPadmin) but come with a GUI/TUI. Something like authconfig-gtk in CentOS.
Nox (240 rep)
May 28, 2018, 01:19 PM • Last activity: Apr 21, 2025, 05:02 AM
1 votes
3 answers
87 views
Authenticate with a physical button
I have a Raspberry PI Pico laying around and I was thinking about creating a device that, when I need to authenticate myself on Linux, I could just click a button soldered to the Pico, which would then send a message to the computer that would authenticate myself. This device would be connected to a...
I have a Raspberry PI Pico laying around and I was thinking about creating a device that, when I need to authenticate myself on Linux, I could just click a button soldered to the Pico, which would then send a message to the computer that would authenticate myself. This device would be connected to a secure computer, so no problem. The question is, how can I do it? I have no experience with Linux programming, so I don't know if there's already a service or library that could be used for that. I know that YubiKey has devices with a button that works something like that, but I also read that they need internet connection to work, which is a no-no.
arslivinski (9 rep)
Apr 14, 2025, 03:41 PM • Last activity: Apr 15, 2025, 10:46 PM
3 votes
1 answers
9705 views
WBC_ERR_DOMAIN_NOT_FOUND only for a specific account
Platform: RHEL 5.10 Version: Samba 3.6.6-0.136 Only on a single VM, one of my co-workers is able to log into the VM using his AD credentials without issue, whereas my account appears to have trouble locating user information: [root@ncxxxlwb05 ~]# wbinfo -i myDom.mjplakus XXX.mjplakus:*:16777224:1677...
Platform: RHEL 5.10 Version: Samba 3.6.6-0.136 Only on a single VM, one of my co-workers is able to log into the VM using his AD credentials without issue, whereas my account appears to have trouble locating user information: [root@ncxxxlwb05 ~]# wbinfo -i myDom.mjplakus XXX.mjplakus:*:16777224:16777229::/home/XXX/mjplakus:/bin/bash [root@ncxxxlwb05 ~]# wbinfo -i myDom.jadavis6 failed to call wbcGetpwnam: WBC_ERR_DOMAIN_NOT_FOUND Could not get info for user xxx.jadavis6 Thinking that winbind could have just cached a negative return (for instance AD wasn't available when it had to refresh its cache entry for my user account) I set both winbind cache time and idmap negative cache time to be 1 second but I got the same results. Same results with above cache values and doing net cache flush several times. I didn't find anything in /var/log/samba/* under normal debug levels so I set debug level = 8 and this started being printed in the logs when I tried to resolve my name: [2013/12/05 14:21:59.795061, 3] winbindd/winbindd_getpwnam.c:56(winbindd_getpwnam_send) getpwnam myDom.jadavis6 [2013/12/05 14:21:59.795161, 1] ../librpc/ndr/ndr.c:414(ndr_pull_error) ndr_pull_error(13): value out of range [2013/12/05 14:21:59.795219, 5] winbindd/winbindd_getpwnam.c:137(winbindd_getpwnam_recv) Could not convert sid S-1-5-21-652622394-3291385539-1351089441-10771: NT_STATUS_INVALID_PARAMETER [2013/12/05 14:21:59.795391, 6] winbindd/winbindd.c:869(winbind_client_request_read) closing socket 29, client exited Which seems like it contains the actual problem but I don't know how to read the error and would like some guidance on this. It seems like it doesn't like the SID associated with my AD account for some reason, but I don't know why or how to work around it. I'm present in the active directory domain referenced, but for some reason it's unable to pull only my account's information.
Bratchley (17244 rep)
Dec 5, 2013, 07:29 PM • Last activity: Apr 13, 2025, 10:04 AM
1 votes
1 answers
1192 views
No Authentication Agent Found Although Already Running
I have an Alpine-Linux based system (PostmarketOS) running with the LXQT DE. Ever since I set up the system, out of the box it came with a bunch of problems with user authentication. I have various problems, including: - Whenever I plug in a USB thumb drive, I get a message saying "Error: not author...
I have an Alpine-Linux based system (PostmarketOS) running with the LXQT DE. Ever since I set up the system, out of the box it came with a bunch of problems with user authentication. I have various problems, including: - Whenever I plug in a USB thumb drive, I get a message saying "Error: not authorized to perform operation." - If I try to run any downloaded program such as Gparted which requires authentication, I don't get a popup message prompting for my password, and instead get the message "Error executing command as another user: No authentication agent found." - If I try to edit the user settings with any built-in tools such as the LXQT Configuration Center, I get the same error. enter image description here After investigating this for a while, I noticed that it seems like the authentication agent is already running. It's set to autostart and I can see it running in the system monitor: enter image description here If I try to run pkttyagent -p $(echo $$) | lxqt-sudo gparted then I get the popup to finally appear: enter image description here Therefore, I have reason to believe that the required programs are on my system since I see them running and I'm able to run them manually with the command line. However, I am unable to figure out why the sudo GUI frontend never pops up automatically when an application is requesting superuser permissions, and why I can't perform basic actions such as using my USB thumb drive or change system settings. I set the root user password and logged in to the root user account, and don't face any of these issues there. So there is something wrong with the setup for the authentication agent or polkit in general and I'm not sure what to do. Help would be greatly appreciated. Thank you for your time.
Hexyl Cinnamal (21 rep)
Jun 6, 2022, 03:56 PM • Last activity: Apr 12, 2025, 01:16 PM
3 votes
1 answers
3897 views
SVN errors E170013, E120190 - An error occurred during authentication
I am trying to connect to my company SVN server in Ubuntu 16.04 and keep getting the following errors: $ svn list https://path_to_repo svn: E170013: Unable to connect to a repository at URL 'https://path_to_repo' svn: E120190: Error running context: An error occurred during authentication Note that...
I am trying to connect to my company SVN server in Ubuntu 16.04 and keep getting the following errors: $ svn list https://path_to_repo svn: E170013: Unable to connect to a repository at URL 'https://path_to_repo ' svn: E120190: Error running context: An error occurred during authentication Note that normally everyone else in the company is using Windows to access the server and I am using Linux because of embedded development (of which I am the only one...). The SVN server runs on Windows so I was wondering if there is something missing from the server configuration on Windows that would prevent access from a Linux machine. For what it's worth, I am able to connect to the VisualSVN server and view files. I just can't use any svn commands from the command line without getting the errors mentioned earlier. Any help would be greatly appreciated!
skrawn (41 rep)
Oct 12, 2016, 03:18 PM • Last activity: Mar 29, 2025, 11:02 AM
Showing page 1 of 20 total questions