Skip to content

pkg/generator: add generation for docker image building scripts#69

Merged
fanminshi merged 3 commits intooperator-framework:masterfrom
fanminshi:gen_docker_build
Feb 28, 2018
Merged

pkg/generator: add generation for docker image building scripts#69
fanminshi merged 3 commits intooperator-framework:masterfrom
fanminshi:gen_docker_build

Conversation

@fanminshi
Copy link
Copy Markdown
Contributor

@fanminshi fanminshi commented Feb 27, 2018

add code generation for docker image build scripts. those are the scripts that operator-sdk build $IMAGE can use to create the operator image.

@fanminshi
Copy link
Copy Markdown
Contributor Author

Manual Test:

$ operator-sdk new app-operator-2 --api-version=app.example.com/v1alpha1 --kind=AppService
$ cd app-operator-2/tmp/build/
$ cat docker_build.sh
#!/usr/bin/env bash

if ! which docker > /dev/null; then
	echo "docker needs to be installed"
	exit 1
fi

: ${IMAGE:?"Need to set IMAGE, e.g. gcr.io/<repo>/<your>-operator"}

echo "building container ${IMAGE}..."
docker build -t "${IMAGE}" -f tmp/build/Dockerfile .
fanmins-MBP:build fanminshi$ cat Dockerfile
FROM alpine:3.6

ADD tmp/_output/bin/app-operator-2 /usr/local/bin/app-operator-2

RUN adduser -D app-operator-2
USER app-operator-2
fanmins-MBP:build fanminshi$ cat Dockerfile
FROM alpine:3.6

ADD tmp/_output/bin/app-operator-2 /usr/local/bin/app-operator-2

RUN adduser -D app-operator-2
USER app-operator-2

@fanminshi
Copy link
Copy Markdown
Contributor Author

cc/ @hasbro17 @hongchaodeng

1 similar comment
@fanminshi
Copy link
Copy Markdown
Contributor Author

cc/ @hasbro17 @hongchaodeng

@hasbro17
Copy link
Copy Markdown
Contributor

LGTM

@fanminshi fanminshi merged commit 52fe353 into operator-framework:master Feb 28, 2018
@fanminshi fanminshi mentioned this pull request Feb 28, 2018
21 tasks
jmrodri referenced this pull request in jmrodri/operator-sdk Feb 4, 2022
- chore: bump go 1.17, k8s 1.23, and kubebuilder 3.3 (#69)
- chore(deps): update to Quarkus SDK extension 3.0.2 and Quarkus 2.6.3 (#70)
- chore(deps): update to use Quarkus JOSDK extension 3.0.1 (#67)
- Remove useless file (#65)
- chore: bump k8s 1.22.2 and kubebuilder 3.2 (#64)
- exposed exnpoints for micrometer metrics (#45)
- modified the Quarkus operator SDK version and tutorial too (#40)
- chore: bump fabric8 5.8.0 & quarkus 2.4.0 (#42)
- modified the doc file and removed file after generation (#41)
- release: fix release script to understand release branches (#38)

- Fix for wrongly generated file name (#73)

Signed-off-by: jesus m. rodriguez <jesusr@redhat.com>
jmrodri referenced this pull request in jmrodri/operator-sdk Feb 4, 2022
Additions:

- chore: bump go 1.17, k8s 1.23, and kubebuilder 3.3 (#69)
- chore(deps): update to Quarkus SDK extension 3.0.2 and Quarkus 2.6.3 (#70)
- chore(deps): update to use Quarkus JOSDK extension 3.0.1 (#67)
- Remove useless file (#65)
- chore: bump k8s 1.22.2 and kubebuilder 3.2 (#64)
- exposed exnpoints for micrometer metrics (#45)
- modified the Quarkus operator SDK version and tutorial too (#40)
- chore: bump fabric8 5.8.0 & quarkus 2.4.0 (#42)
- modified the doc file and removed file after generation (#41)
- release: fix release script to understand release branches (#38)

Bug Fixes:

- Fix for wrongly generated file name (#73)

Signed-off-by: jesus m. rodriguez <jesusr@redhat.com>
jmrodri referenced this pull request in jmrodri/operator-sdk Feb 17, 2022
Additions:

- chore: bump go 1.17, k8s 1.23, and kubebuilder 3.3 (#69)
- chore(deps): update to Quarkus SDK extension 3.0.2 and Quarkus 2.6.3 (#70)
- chore(deps): update to use Quarkus JOSDK extension 3.0.1 (#67)
- Remove useless file (#65)
- chore: bump k8s 1.22.2 and kubebuilder 3.2 (#64)
- exposed exnpoints for micrometer metrics (#45)
- modified the Quarkus operator SDK version and tutorial too (#40)
- chore: bump fabric8 5.8.0 & quarkus 2.4.0 (#42)
- modified the doc file and removed file after generation (#41)
- release: fix release script to understand release branches (#38)

Bug Fixes:

- Fix for wrongly generated file name (#73)

Signed-off-by: jesus m. rodriguez <jesusr@redhat.com>
jmrodri added a commit that referenced this pull request Feb 17, 2022
Additions:

- chore: bump go 1.17, k8s 1.23, and kubebuilder 3.3 (#69)
- chore(deps): update to Quarkus SDK extension 3.0.2 and Quarkus 2.6.3 (#70)
- chore(deps): update to use Quarkus JOSDK extension 3.0.1 (#67)
- Remove useless file (#65)
- chore: bump k8s 1.22.2 and kubebuilder 3.2 (#64)
- exposed exnpoints for micrometer metrics (#45)
- modified the Quarkus operator SDK version and tutorial too (#40)
- chore: bump fabric8 5.8.0 & quarkus 2.4.0 (#42)
- modified the doc file and removed file after generation (#41)
- release: fix release script to understand release branches (#38)

Bug Fixes:

- Fix for wrongly generated file name (#73)

Signed-off-by: jesus m. rodriguez <jesusr@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants