Harbor Image Push¶
Image Capacity and Artifact Retention
Image Capacity
The Harbor registry is currently only capable of holding five versions of an image. If more than five are pushed, the system will automatically purge the oldest version. We are working to expand the image capacity.
Artifact Retention
The Game Warden application triggers pipelines continuously and produces artifacts for each pipeline. As such, these artifacts will continue to build and take up storage space. To avoid unnecessary lag, the Game Warden app purges any artifacts over 15 days old.
This means you will have 15 days after pushing images to initiate the pipeline to push to DEV, STG, or PRD. After 15 days, Game Warden will purge the artifacts necessary to push your images. You will need to update your images in Game Warden after that time period. Please note that purged artifacts will not be accessible after the 15 days time period.
The steps below provide a series of sample commands entered by user, Jane Doe (whose username is janed). Jane is a member of test-company (which is also the name of her project) and will push a new image, test-image. The image tag is 0.0.1.
- Open a terminal session, accessing the command line.
- You will type the Username and paste the CLI secret.
-
Type:
docker login -u `username` -p `cli-secret` registry.gamewarden.io/
- Example:
docker login -u janed -p password123 registry.gamewarden.io/
- Example:
-
Click Enter.
- Several lines display, including Login Succeeded (if accurate credentials entered). You have successfully accessed Harbor from your local machine. If your login credentials fail, ensure you have an authenticated/active Harbor session running from your web browser. Next, you must re-tag your image.
Do not use the following for your image tag: - "-hardened" - "latest" - ".sig" - "sha256" - "development" - "staging" - "production" Your app's Deployment Passport requires a specific image version number and Harbor will not recognize the above tags so your pushed images will not be run through the pipelines. Instead, tag your images with the latest version number (for example, 0.2.1) in accordance with Semantic Versioning principles.
- Several lines display, including Login Succeeded (if accurate credentials entered). You have successfully accessed Harbor from your local machine. If your login credentials fail, ensure you have an authenticated/active Harbor session running from your web browser. Next, you must re-tag your image.
-
Type:
docker tag SOURCE_IMAGE[:TAG] registry.gamewarden.io/test-company/REPOSITORY[:TAG]
-
Example:
docker tag your-registry/your-project/previous-image-name:previous-tag registry.gamewarden.io/test-company/test-image:0.0.1
-
This command identifies the source/previous image name and tag information then references the image name and associated tag specific to the image you are pushing.
-
-
Type (optionally):
docker image ls
- This command enables you to view a list of your existing images (void of other files).
- Example Output: -
- This command enables you to view a list of your existing images (void of other files).
-
Type:
docker push registry.gamewarden.io/your-project/image:tag
- Example:
docker push registry.gamewarden.io/test-company/test-image:0.0.1
- Several lines display. You have pushed your image into the Harbor registry.
- Example:
-
Return to Harbor to confirm that you have successfully pushed your image into this environment.
- Click to select your project from the Projects page.
- A new page opens, defaulting to the Repositories tab.
-
Identify your new image in the available table, which verifies that you have successfully pushed your image into Harbor.
- If your new image is not present, please review your previous steps carefully and determine if any Error or Warning messages were triggered in your terminal session. Also, ensure you are authorized to push images into Harbor on behalf of your company. Contact our Customer Operations team via Slack for further guidance.
- After you successfully push an image into Harbor, a webhook updates Docker files then triggers a pipeline that builds and hardens the image. You will be able to view the hardened image in Harbor.
- If your new image is not present, please review your previous steps carefully and determine if any Error or Warning messages were triggered in your terminal session. Also, ensure you are authorized to push images into Harbor on behalf of your company. Contact our Customer Operations team via Slack for further guidance.
Note
If you continually push the same image into Harbor (with the a new tag), pipelines are triggered for each. Each tag will be available in Harbor. The image line item identifies the most recent date/time you pushed this image tag.
Last Updated: 06/20/2024
Feedback
Was this article helpful? Want to see something more?
Please reach out to us here with your feedback.