Issues with building dockerfile in local mode

local-mode

#1

Hey,

I’m currently trying to get local mode working for my development device.

I’m running into issues with the local push command.

  1. I don’t see an easy way to specify which Dockerfile to use. Currently I’m duplicating my actual prod file and writing it to Dockerfile.
  2. I am getting push failures when using the *%%RESIN_ARCH%% and %%RESIN_MACHINE_NAME%% syntax in my dockerfile. Is there a good way to run local mode with these values present?

Thanks for the help!


#4

Hi,
For now, creating a Dockerfile based on your Dockerfile.template is the way to get resin local to work.
You can track progress on our effort making Dockerfile.templates to also work in https://github.com/resin-io/resin-cli/issues/604 .

Back in your issue.
You should replace %%RESIN_MACHINE_NAME%% and %%RESIN_ARCH%% in your Dockerfile with the appropriate values for your device, as found in https://docs.resin.io/deployment/docker-templates/ . For example, for a Raspberry Pi 3 app you should use raspberrypi3 and armv8hf respectively.

Give us a note if you face any issues.


#6

Awesome! That’s worked for us!

Thanks!