Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support writefile step in pipeline #1026

Open
chilianyi opened this issue Nov 23, 2023 · 0 comments
Open

Support writefile step in pipeline #1026

chilianyi opened this issue Nov 23, 2023 · 0 comments
Assignees
Labels
kind/feature Categorizes issue or PR as related to a new feature.

Comments

@chilianyi
Copy link
Contributor

What is version of KubeSphere DevOps has the issue?

v3.4.1

How did you install the Kubernetes? Or what is the Kubernetes distribution?

kubekey

Describe this feature

截屏2023-11-23 12 17 13
pipeline {
    agent any

    stages {
        stage('Generate Dockerfile and Build Image') {
            steps {
              writeFile file: 'test', text: '''
              abcdefg
              '''
              
              writeFile file: 'Dockerfile', text: '''
                  FROM nginx:latest
                  ADD test ./
              '''

              sh "docker build -t test:latest ."
            }
        }
    }
}

Additional information

No response

@chilianyi chilianyi added the kind/feature Categorizes issue or PR as related to a new feature. label Nov 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/feature Categorizes issue or PR as related to a new feature.
Projects
None yet
Development

No branches or pull requests

2 participants