Skip to content
This repository has been archived by the owner on Sep 10, 2022. It is now read-only.

Adds Dockerfile #32

Merged
merged 1 commit into from
Jun 9, 2020
Merged

Adds Dockerfile #32

merged 1 commit into from
Jun 9, 2020

Conversation

sladyn98
Copy link
Contributor

@sladyn98 sladyn98 commented Jun 3, 2020

Added simple dockerfile for frontend and backend to be able to run the project easily.

@sladyn98 sladyn98 added the chore label Jun 3, 2020
@sladyn98 sladyn98 added this to the [GSoC Phase 1] milestone Jun 3, 2020
@sladyn98 sladyn98 requested a review from a team as a code owner June 3, 2020 14:12
@sladyn98
Copy link
Contributor Author

sladyn98 commented Jun 3, 2020

I will add new lines at the end of the files if required :)

ARG JAR_FILE=target/custom-distribution-service-0.0.1.jar

# Add the application's jar to the container
ADD ${JAR_FILE} custom-distribution-service.jar
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copy link
Contributor

@kwhetstone kwhetstone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For testing these files together, do you want to put together a docker-compose? Adding directions to the README will help too.

@sladyn98
Copy link
Contributor Author

sladyn98 commented Jun 4, 2020

@kwhetstone Yeah my initial aim was to get a docker compose file but the front end service throws a ton of errors when run using a docker compose, I will instead add instructions to the readme just so that we can run these separately.

@LinuxSuRen
Copy link
Member

I will add new lines at the end of the files if required :)

You can find some reasons for it from here.

@sladyn98
Copy link
Contributor Author

sladyn98 commented Jun 4, 2020

Commands for running the front end are, these should be run from the front-end directory
docker build -t cds_react:dev .
docker run \ -it \ --rm \ -v ${PWD}:/app \ -v /app/node_modules \ -p 3001:3000 \ -e CHOKIDAR_USEPOLLING=true \ cds_react:dev

Could you just try this on your local machine and see if it running because it is throwing me a bunch of errors @LinuxSuRen

@LinuxSuRen
Copy link
Member

I can run it by the following command:
docker run -it --rm -v ${PWD}:/app -p 3001:3000 -e CHOKIDAR_USEPOLLING=true cds_react:dev

But I'm not sure it can really work.

@sladyn98
Copy link
Contributor Author

sladyn98 commented Jun 4, 2020

@LinuxSuRen the command is failing on my machine I mean the docker container is still not running

@sladyn98 sladyn98 requested a review from kwhetstone June 4, 2020 19:16
@sladyn98
Copy link
Contributor Author

sladyn98 commented Jun 4, 2020

I generated the package-lock.json again @kwhetstone in order to make this run. I also removed the eslint scripts. I guess we can just add them later

@kwhetstone
Copy link
Contributor

I think the big thing for this was to use eslint 6 instead of 7 since it was causing issues. I know they're different, and eslint 6 will be supported for a bit here since there's so much built on it.

@sladyn98 sladyn98 mentioned this pull request Jun 5, 2020
4 tasks
@sladyn98
Copy link
Contributor Author

sladyn98 commented Jun 5, 2020

This file now only contains the dockerfile update, and the eslint version has been fixed in another PR here it is #37 . So kindly merge that before this one.

Copy link
Contributor

@kwhetstone kwhetstone left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let's get this in.

@sladyn98
Copy link
Contributor Author

sladyn98 commented Jun 9, 2020

@kwhetstone Roger that 🚀

@sladyn98 sladyn98 merged commit 2b4fa2a into jenkinsci:master Jun 9, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants