* Fix ConfigMap name clash if env_file name is equal #2000
* Generate envFrom instead of single env entries from env_file entries #1999
* Fix failing test fixture outputs
#### What type of PR is this?
<!--
Add one of the following kinds:
/kind bug
/kind documentation
/kind feature
-->
/kind cleanup
#### What this PR does / why we need it:
Fixes the two flakey tests. One which is returning them in random
orders..
The other which is not available to run on mac due to not being able
"access" the folders.
#### Which issue(s) this PR fixes:
<!--
*Automatically closes linked issue when PR is merged.
Usage: `Fixes #<issue number>`, or `Fixes (paste link of issue)`.
-->
N/A
#### Special notes for your reviewer:
N/A
Signed-off-by: Charlie Drage <charlie@charliedrage.com>
fallback to skip volume mount and log warning when path cannot be resolved, as /sys, /root, /var/lib/docker
in e2e TestMultipleContainersInPod directory /data replaced with /data-dir
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
* adds a label for initContainers, test and user-guide
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
* solved suggestion version from 2 to 3, coments
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
* test e2e
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
* add target to kompose build
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
* chore(deps)(deps): bump golang.org/x/tools from 0.16.1 to 0.19.0 (#1836)
Bumps [golang.org/x/tools](https://github.com/golang/tools) from 0.16.1 to 0.19.0.
- [Release notes](https://github.com/golang/tools/releases)
- [Commits](https://github.com/golang/tools/compare/v0.16.1...v0.19.0)
---
updated-dependencies:
- dependency-name: golang.org/x/tools
dependency-type: direct:production
update-type: version-update:semver-minor
...
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
* changed var names contaers to containers
changed labels to kompose.init.container.name, kompose.init.container.image, kompose.init.container.command
fixed documentation, tests and e2e
also merged main with new commits to this branch
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
---------
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Kubernetes Prow Robot <20407524+k8s-ci-robot@users.noreply.github.com>
add tests and e2e
function isconfigfile check if we need to use configmap and mount in readonly
readonly not asigned because not fail e2e
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
added tests
fixNetworkModeToService is responsible for adjusting the network mode of services in docker compose (services:) and generate a mapping of deployments based on the network mode of each service merging containers into the destination deployment, and removing transferred deployments
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
kompose.hpa.minreplicas
kompose.hpa.maxreplicas
kompose.hpa.cpu
kompose.hpa.memory
documentated labels user_guide.md
generate custom metrics from cpu, memory and set min/max replicas
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
* fix issue 1793 https://github.com/kubernetes/kompose/issues/1793
*add tests
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
formated k8utils_test.go
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
labels formatted as name"-"envName to match fixtures when performing the gitHub action
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
removed this piece code because apply it later, and it is redundant
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
Refactor test in k8sutils_test.go to extract the last 63 characters. This addresses the impact of the removed code that previously truncated the input with if len(envName) > 63 { envName = envName[len(envName)-63:] }
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
changed to name function to getUsableNameEnvFile
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
fix issue 1793
* fix issue 1793 https://github.com/kubernetes/kompose/issues/1793
*add tests
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
labels formatted as name"-"envName to match fixtures when performing the gitHub action
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
changed to name function to getUsableNameEnvFile
Signed-off-by: jose luis <2064537+sosan@users.noreply.github.com>
* feat: migrate from libcompose to compose-go
libcompose has been deprecated since summer 2021 in favor of https://github.com/compose-spec/compose-go.
Kompose should now be able to load all versions of compose.
* chore: replace golint with staticcheck
golint has been deprecated. Recommended replacement is staticcheck.
* Use go mod instead of glide
* Add `--with-kompose-annotation` flag to allow us to switch it off for tests
* Remove hostpid support (since the newest sdk does not support it)
* Create new test script and fixtures
* Remove replicationcontroller support
solve #610
convert service.pid to Pod.Spec.HostPid
set Pod.Spec.HostPid to true if service.pid ="host", to false otherwise
update conversion.md on support for the key
Resolves#272 and #267
As there is no direct mapping of `cpushares` and `cpuset` to kubernetes,
it should not be read and should be moved to unsupported keys.