Skip to content

Commit

Permalink
Merge pull request #519 from ditrit/feature/arg_in_dockerfile
Browse files Browse the repository at this point in the history
Improve dockerfile
  • Loading branch information
Zorin95670 authored Jul 9, 2024
2 parents 0cd8a74 + 8e8d7c4 commit 2deff17
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
9 changes: 6 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,13 @@ RUN npm install
# Build stage
FROM develop-stage as build-stage
ARG proxy_url
ARG TERRATOR_PLUGIN_VERSION
ARG GITHUBATOR_PLUGIN_VERSION
ARG KUBERNATOR_PLUGIN_VERSION
WORKDIR /app
RUN npm run plugin:install -- repository-name="terrator-plugin" repository-url="https://github.com/ditrit/terrator-plugin.git#0.8.1"
RUN npm run plugin:install -- repository-name="githubator-plugin" repository-url="https://github.com/ditrit/githubator-plugin.git#0.3.3"
RUN npm run plugin:install -- repository-name="kubernator-plugin" repository-url="https://github.com/ditrit/kubernator-plugin.git#0.1.0"
RUN npm run plugin:install -- repository-name="terrator-plugin" repository-url="https://github.com/ditrit/terrator-plugin.git#${TERRATOR_PLUGIN_VERSION}"
RUN npm run plugin:install -- repository-name="githubator-plugin" repository-url="https://github.com/ditrit/githubator-plugin.git#${GITHUBATOR_PLUGIN_VERSION}"
RUN npm run plugin:install -- repository-name="kubernator-plugin" repository-url="https://github.com/ditrit/kubernator-plugin.git#${KUBERNATOR_PLUGIN_VERSION}"
RUN npm run plugin:init
RUN npm run build

Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ It will generate the built application in the `dist` folder.

To build this app with docker (the two main plugins for terraform & github are included), please use this command:
```bash
docker build . -t leto-modelizer
docker build . -build-arg TERRATOR_PLUGIN_VERSION="0.8.1" -build-arg GITHUBATOR_PLUGIN_VERSION="0.3.3" -build-arg KUBERNATOR_PLUGIN_VERSION="0.1.0" -t leto-modelizer
```

### Docker run
Expand Down
1 change: 1 addition & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
* `CF_createProject`: allows or prevents user to create a project.
* Add settings button/menu to homepage and update its content.
* Add route to clear token.
* Improve dockerfile with version of plugins as argument.

### Changed

Expand Down

0 comments on commit 2deff17

Please sign in to comment.