Skip to content

Commit

Permalink
Merge pull request #686 from juanmanuel-tirado/JUJU-1361_upgrade_ubun…
Browse files Browse the repository at this point in the history
…tu_example_charm

Revision of test onos.charm
  • Loading branch information
juanmanuel-tirado authored Jun 24, 2022
2 parents bd9490d + f101dd7 commit d6bafce
Show file tree
Hide file tree
Showing 14 changed files with 315 additions and 976 deletions.
Binary file modified examples/charms/onos.charm
Binary file not shown.
7 changes: 7 additions & 0 deletions examples/charms/ubuntu/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
venv/
build/
*.charm

.coverage
__pycache__/
*.py[cod]
3 changes: 3 additions & 0 deletions examples/charms/ubuntu/.jujuignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
/venv
*.py[cod]
*.charm
34 changes: 34 additions & 0 deletions examples/charms/ubuntu/CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
# ubuntu

## Developing

Create and activate a virtualenv with the development requirements:

virtualenv -p python3 venv
source venv/bin/activate
pip install -r requirements-dev.txt

## Code overview

TEMPLATE-TODO:
One of the most important things a consumer of your charm (or library)
needs to know is what set of functionality it provides. Which categories
does it fit into? Which events do you listen to? Which libraries do you
consume? Which ones do you export and how are they used?

## Intended use case

TEMPLATE-TODO:
Why were these decisions made? What's the scope of your charm?

## Roadmap

If this Charm doesn't fulfill all of the initial functionality you were
hoping for or planning on, please add a Roadmap or TODO here

## Testing

The Python operator framework includes a very nice harness for testing
operator behaviour without full deployment. Just `run_tests`:

./run_tests
876 changes: 202 additions & 674 deletions examples/charms/ubuntu/LICENSE

Large diffs are not rendered by default.

16 changes: 0 additions & 16 deletions examples/charms/ubuntu/README

This file was deleted.

24 changes: 24 additions & 0 deletions examples/charms/ubuntu/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
# ubuntu

## Description

A simple Ubuntu image for testing purposes.

## Usage

Nothing relevant simply to be deployed for testing.


## Relations

NA.

## OCI Images

NA.

## Contributing

Please see the [Juju SDK docs](https://juju.is/docs/sdk) for guidelines
on enhancements to this charm following best practice guidelines, and
`CONTRIBUTING.md` for developer guidance.
16 changes: 16 additions & 0 deletions examples/charms/ubuntu/actions.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Copyright 2022 jtirado
# See LICENSE file for licensing details.
#
# TEMPLATE-TODO: change this example to suit your needs.
# If you don't need actions, you can remove the file entirely.
# It ties in to the example _on_fortune_action handler in src/charm.py
#
# Learn more about actions at: https://juju.is/docs/sdk/actions

fortune:
description: Returns a pithy phrase.
params:
fail:
description: "Fail with this message"
type: string
default: ""
10 changes: 10 additions & 0 deletions examples/charms/ubuntu/charmcraft.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Learn more about charmcraft.yaml configuration at:
# https://juju.is/docs/sdk/charmcraft-config
type: "charm"
bases:
- build-on:
- name: "ubuntu"
channel: "22.04"
run-on:
- name: "ubuntu"
channel: "22.04"
7 changes: 6 additions & 1 deletion examples/charms/ubuntu/config.yaml
Original file line number Diff line number Diff line change
@@ -1 +1,6 @@
options: {}
# Copyright 2022 jtirado
# See LICENSE file for licensing details.
#
# Learn more about config at: https://juju.is/docs/sdk/config

options: {}
Loading

0 comments on commit d6bafce

Please sign in to comment.