Pushing docker image to newly created Digital Ocean droplet
Required Digital Ocean token (How to get it https://docs.docker.com/machine/examples/ocean/)
Droplet name to be created
Exposed ports in 00:00 format
Image name you created in previous steps
File name you created in previous steps
Newly created droplet ip
uses: iambeone/pushtodigitalocean@master
with:
token: ${{ secrets.token }}
ports: 4000:4000
image: myimage
file: myimage.tgz
name: dropletnametobecreated
- name: Build image
run: docker build -t myimage .
- name: Save file
run: docker save myimage | gzip > myimage.tgz
- name: push to do
uses: iambeone/pushtodigitalocean@master
with:
token: ${{ secrets.token }}
ports: 4000:4000
image: myimage
file: myimage.tgz
name: dropletnametobecreated