-
Notifications
You must be signed in to change notification settings - Fork 278
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Please provide a Dockerfile for a development environment to make it easier to get up and running #490
Comments
Can you explain what is wrong? So in reality all you need is:
|
Urgh, I jumped the gun a bit (seems like we are on old CMock version). Nowadays you can use Ruby3 based on github actions: https://github.com/ThrowTheSwitch/CMock/blob/master/.github/workflows/main.yml#L17-L22 So that's about what you need: a ruby3 container. |
I meant something like this Dockerfile:
I'm new to Ruby and followed the "Getting Started" section of /README.md. The instructions fails on "bundle: not found" since I don't have the "bundle" program installed and I don't know what that program is or where to get it from.. That's why a Dockerfile that automates the whole process would be nice. Then it is also possible to repeat the steps from the Docker file manually on the workstation for those that don't want to use a containerized environment. |
Uh, if you clone it in docker container, then you will lose the progress once container is shut down. Also without a key linked into it there is no way to commit nicely. So what you usually do you map the folder to inside the container and then inside the container you need to run bundle install and other commands Maybe we should have rather use Here is docker command to map and run tests (copied from Ruby Dockerhub page):
Docker compose would be something like:
services:
test:
image: ruby:3
volumes:
- .:/usr/src/app
working_dir: /usr/src/app
command:
- bundle install
- cd test && rake And you run that with |
The Dockerfile above is just an example of what's happening if you follow the README.md instructions on a computer with a newly installed Ubuntu. So don't focus on the docker-related stuff. I use Ubuntu on my workstation and the instructions in the README.md didn't work. |
Thats then different discussion. What was missing? ruby-bundler? |
I guess so. It's some program called bundle.
|
add |
Thank you for your quick response, it is much appreciated!
|
I added clone Disclamer again: This above example includes a bunch of bad practices for active development and running of the build (rake) inside the Docker containers. |
I don't know if it worked for you, but for me it didn't. :(
|
Sorry, I am not testing commands, I am just putting suggestions of what could be wrong based on error message. Maybe you need before 5/6 command (bundle install)
Not sure (taken from the .github/workflows/main.yml). |
I'm new to Ruby and the experience of setting up Ruby and the dependencies for getting CMock up and running in a container sucks! I didn't even manage to evaluate CMock because of Ruby. I guess I'm alone with this experience and it's sad that CMock doesn't even get a chance of being used because of this.
Please provide a Dockerfile for building a complete development environment for testing the project using the latest standard Ubuntu/Debian image.
The text was updated successfully, but these errors were encountered: