Deploy candidate is failing

I am getting this error in Agent job:


Here’s the data:

{
    "command": "docker login -u AWS -p a_veryyyy_long_password public.ecr.aws/v8g8g1h2",
    "directory": "/home/frappe/agent",
    "duration": "0:00:02.526179",
    "end": "2025-06-30 18:08:11.872381",
    "output": "WARNING! Using --password via the CLI is insecure. Use --password-stdin.\ntime=\"2025-06-30T23:53:11+05:45\" level=info msg=\"Error logging in to endpoint, trying next endpoint\" endpoint=\"{false https://public.ecr.aws false false false 0xc000344b40}\" error=\"login attempt to https://public.ecr.aws/v2/ failed with status: 400 Bad Request\"\nlogin attempt to https://public.ecr.aws/v2/ failed with status: 400 Bad Request",
    "returncode": 1,
    "start": "2025-06-30 18:08:09.346202",
    "status": "Failure",
    "traceback": "Traceback (most recent call last):\n  File \"/home/frappe/agent/repo/agent/base.py\", line 60, in execute\n    output, returncode = self.run_subprocess(\n  File \"/home/frappe/agent/repo/agent/base.py\", line 111, in run_subprocess\n    raise subprocess.CalledProcessError(returncode, command, output=output)\nsubprocess.CalledProcessError: Command 'docker login -u AWS -p a_very_long_password public.ecr.aws/v8g8g1h2' returned non-zero exit status 1.\n"
}

Here is my press setting:

Docker registry password was created by using this command:

 aws ecr-public get-login-password --region us-east-1 | docker login --username AWS --password-stdin public.ecr.aws/some_random_text_given_by_aws

I copied the key from the file saved in ~/.docker/config.json after running above command.

Another Agent job throws this error at the same time:

Give the frappe user thats doing the build a socket permission of chmod 666

Hello,
thank you.

Is that to be done on f,n or m server or on the server running this Press UI ?

Also, are you referring to sudo chmod 666 /var/run/docker.sock ?

For future reference,

run:
sudo chmod 666 /var/run/docker.sock on f server.