Inedo Community Forums Forums
    • Recent
    • Tags
    • Popular
    • Login

    Welcome to the Inedo Forums! Check out the Forums Guide for help getting started.

    If you are experiencing any issues with the forum software, please visit the Contact Form on our website and let us know!

    Deployment pipleline issue

    Scheduled Pinned Locked Moved Support
    buildmaster
    3 Posts 1 Posters 1 Views
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • ? This user is from outside of this forum
      Guest
      last edited by

      Hopefully I can describe this in an understandable way...

      We are building artifacts in Jenkins and placing them in artifactory along with a deployment script.

      As we deploy from buildmaster we are getting the artifacts from an artifactory repository, deploying them to an envrionment, and then moving them from the original artifactory repository to the next one. The idea being that the environments that we deploy to dev, sit, uat, prd are matched in artifactory.

      The problem comes when we look at forcing a deployment to an environment further down the chain as we cannot grab the artifacts from the previous envrionment because its not there.

      How would you recommed we deal with artifacts in this type of approach?

      Caveats:

      • We cannot use BuildMasters built in artifact management due to corprate standards
      • We need to automatically cleanup old artifacts in artifactory (hence the idea of a repository per envrionment where we'd just keep the last few deployments to each envrionment, copying from the previous repository to the new one as it gets deployed)

      I'm now wondering if it's feasible to have a single repository with all every artifact ever built, but automatically delete builds that have been rejected or overridden by subsequent deployment to an envrionment. Not sure if your api can provide that sort of info...

      Cheers
      Andrew

      Product: BuildMaster
      Version: 4.5.3

      1 Reply Last reply Reply Quote 0
      • ? This user is from outside of this forum
        Guest
        last edited by

        Hi Andrew,

        I chatted with a few folks here, and we're not exactly sure the best way to accomplish given the constraints :)

        The idea of a "single repository with every artifact" seems like a good approach, based on my understanding of the requirements, and you could make an event listener that listens to "Release Deployed" or "Build Rejected" to then go and purges artifacts.

        I'm not sure if that helps?

        1 Reply Last reply Reply Quote 0
        • ? This user is from outside of this forum
          Guest
          last edited by

          I hadn't thought of using BuildMaster like that. What I have implemented and seems to work well is a groovy script that make use of the BuildMaster and Artifactory json api's:

          1. Get List of all envrionment for this Application using GetEnvironments api
          2. For each environment get a list of the last 'X' builds and add to a list of of versions to keep using GetExecutions. As a build may get reapplied to the same envrionment several times to repair a failed deployment I get more than I need and only keep the to X unqiue versions for that environment.
          3. Get a list of folders from Artifactory for our application (each build is stored in seperate folder) using FolderInfo api
          4. For each folder returned, check its in our keep list, if not delete it using DeleteItem api
          1 Reply Last reply Reply Quote 0

          Hello! It looks like you're interested in this conversation, but you don't have an account yet.

          Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.

          With your input, this post could be even better 💗

          Register Login
          • 1 / 1
          • First post
            Last post
          Inedo Website Home • Support Home • Code of Conduct • Forums Guide • Documentation