Skip to content

Conversation

@potiuk
Copy link
Member

@potiuk potiuk commented Jun 27, 2020

OpenShift (and other Kubernetes platforms) often use the approach
that they start containers with random user and root group. This is
described in the https://docs.openshift.com/container-platform/3.7/creating_images/guidelines.html

All the files created by the "airflow" user are now belonging to
'root' group and the root group has the same access to those
files as the Airflow user.

Additionally, the random user gets automatically added
/etc/passwd entry which is name 'default'. The name of the user
can be set by setting the USER_NAME variable when starting the
container.

Closes #9248
Closes #8706


Make sure to mark the boxes below before creating PR: [x]

  • Description above provides context of the change
  • Unit tests coverage for changes (not needed for documentation changes)
  • Target Github ISSUE in description if exists
  • Commits follow "How to write a good git commit message"
  • Relevant documentation is updated including usage instructions.
  • I will engage committers as explained in Contribution Workflow Example.

In case of fundamental code change, Airflow Improvement Proposal (AIP) is needed.
In case of a new dependency, check compliance with the ASF 3rd Party License Policy.
In case of backwards incompatible changes please leave a note in UPDATING.md.
Read the Pull Request Guidelines for more information.

@potiuk
Copy link
Member Author

potiuk commented Jun 27, 2020

cc @altunbaratli @flymg

@potiuk potiuk added this to the Airflow 1.10.11 milestone Jun 27, 2020
@potiuk potiuk requested a review from mik-laj June 27, 2020 11:01
@potiuk potiuk force-pushed the makep-prod-dockerfile-openshift-compatible branch from 672bac2 to 1bef8ff Compare June 27, 2020 11:03
OpenShift (and other Kubernetes platforms) often use the approach
that they start containers with random user and root group. This is
described in the https://docs.openshift.com/container-platform/3.7/creating_images/guidelines.html

All the files created by the "airflow" user are now belonging to
'root' group and the root group has the same access to those
files as the Airflow user.

Additionally, the random user gets automatically added
/etc/passwd entry which is name 'default'. The name of the user
can be set by setting the USER_NAME variable when starting the
container.

Closes apache#9248
Closes apache#8706
@potiuk potiuk force-pushed the makep-prod-dockerfile-openshift-compatible branch from 1bef8ff to 6cc9de5 Compare June 27, 2020 11:39
@potiuk potiuk merged commit cf510a3 into apache:master Jun 27, 2020
@potiuk potiuk deleted the makep-prod-dockerfile-openshift-compatible branch June 27, 2020 12:29
potiuk added a commit that referenced this pull request Jun 29, 2020
OpenShift (and other Kubernetes platforms) often use the approach
that they start containers with random user and root group. This is
described in the https://docs.openshift.com/container-platform/3.7/creating_images/guidelines.html

All the files created by the "airflow" user are now belonging to
'root' group and the root group has the same access to those
files as the Airflow user.

Additionally, the random user gets automatically added
/etc/passwd entry which is name 'default'. The name of the user
can be set by setting the USER_NAME variable when starting the
container.

Closes #9248
Closes #8706

(cherry picked from commit cf510a3)
@kaxil kaxil added the type:misc/internal Changelog: Misc changes that should appear in change log label Jul 1, 2020
kaxil pushed a commit that referenced this pull request Jul 1, 2020
OpenShift (and other Kubernetes platforms) often use the approach
that they start containers with random user and root group. This is
described in the https://docs.openshift.com/container-platform/3.7/creating_images/guidelines.html

All the files created by the "airflow" user are now belonging to
'root' group and the root group has the same access to those
files as the Airflow user.

Additionally, the random user gets automatically added
/etc/passwd entry which is name 'default'. The name of the user
can be set by setting the USER_NAME variable when starting the
container.

Closes #9248
Closes #8706

(cherry picked from commit cf510a3)
greenape added a commit to Flowminder/FlowKit that referenced this pull request Dec 16, 2020
greenape added a commit to Flowminder/FlowKit that referenced this pull request Jan 4, 2021
cfei18 pushed a commit to cfei18/incubator-airflow that referenced this pull request Mar 5, 2021
OpenShift (and other Kubernetes platforms) often use the approach
that they start containers with random user and root group. This is
described in the https://docs.openshift.com/container-platform/3.7/creating_images/guidelines.html

All the files created by the "airflow" user are now belonging to
'root' group and the root group has the same access to those
files as the Airflow user.

Additionally, the random user gets automatically added
/etc/passwd entry which is name 'default'. The name of the user
can be set by setting the USER_NAME variable when starting the
container.

Closes apache#9248
Closes apache#8706

(cherry picked from commit cf510a3)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:dev-tools type:misc/internal Changelog: Misc changes that should appear in change log

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Docker Image Compatibility with Openshift/Kubernetes User ’airflow' should be in group 'root' in the Docker image

2 participants