#How to re-deploy a docker image source?

35 messages · Page 1 of 1 (latest)

fast oak
#

I deployed a service via docker image (https://docs.railway.app/develop/services#service-source). Now when I call railway up in my github actions (with the RAILWAY_TOKEN set to that service's token), it does not deploy the docker images but instead tries to build my project using nixpacks. How can I instruct Railway to download the latest docker image and deploy it?

Railway Docs

Documentation for Railway

hidden beaconBOT
#

Project ID: 16582eee-f963-4f76-a699-aa37b8edbec1

static brookBOT
#

To help others find answers, you can mark your question as solved via Right click solution message -> Apps -> ✅ Mark Solution

fast oak
#

16582eee-f963-4f76-a699-aa37b8edbec1

green hamlet
#

railway up is used to deploy your local project and has nothing to do with docker images

#

what docker image did you use

fast oak
#

Its from my project

green hamlet
#

then just use the latest tag

#

ghcr.io/ignisda/ryot:latest

fast oak
#

and will it deploy it then?

green hamlet
#

they dont, you have to go and click redeploy in the 3 dot menu

fast oak
#

thats a shame. does the public API have anything that can help me automate this?

#

i think it does

green hamlet
#

yes it does, you would want to setup a github action to call their public graphql api

fast oak
# green hamlet then just use the latest tag

how about caching? Will the image be cached on the Railway builders and when I redeploy, the existing image will be used instead of pulling the latest image. Anything I can do to prevent that?

green hamlet
#

if you redeploy the same image, yes the layers do get cached, if you deploy an entirely new image, no cache

fast oak
#

is there a env variable that instructs railway to not use docker caching mechanism?

green hamlet
#

for now since that is the latest tag

fast oak
green hamlet
#

your image

fast oak
#

my latest image is tagged both v2.18.7 and latest.

green hamlet
#

correct

fast oak
green hamlet
#

because it's a different image

#

different sha hashes

fast oak
green hamlet
#

interesting

fast oak
# green hamlet because it's a different image

thats not how docker works. if you already have a ghcr.io/ignisda/ryot:latest on your machine, it does not check for SHA, just assumes it is the latest (even though it is not and there exists a newer image on the registry).

green hamlet
#

bruh

fast oak