Docker action deprecated and archived

The Docker action was recently deprecated and archived in favor of using run. I want to make sure I do this in the most secure way possible, but the only options I see are:

- name: Docker login
  run: docker login --username ${{ secrets.DOCKER_USERNAME }} --password ${{ secrets.DOCKER_PASSWORD }}


- name: Docker login
  run: echo ${{ secrets.DOCKER_PASSWORD }} | docker login --username ${{ secrets.DOCKER_USERNAME }} --password-stdin

… neither of which feel safe.


1 Like

FWIW, I’m now using the “official” Docker Login action with a Docker Hub access token:

- name: Docker login
  uses: docker/login-action@v1
    username: ${{ secrets.DOCKER_USERNAME }}
    password: ${{ secrets.DOCKER_TOKEN }}