--- /dev/null
+# Copyright 2022 ETSI
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
+# implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+
+*.zip
+*build/
\ No newline at end of file
<!--
- Copyright 2020 Canonical Ltd.
+ Copyright 2022 Canonical Ltd.
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
See the License for the specific language governing permissions and
limitations under the License.
-->
-# Installation
-
-Go to the [OSM User Guide](https://osm.etsi.org/docs/user-guide/03-installing-osm.html#charmed-installation) for the highly available production-grade deployment.
-For a more minimal cluster suitable for testing, deploy the [single instance OSM bundle](https://jaas.ai/osm/bundle).
+# Charmed OSM
# Bundle Components
- [grafana](https://jaas.ai/u/charmed-osm/grafana/0): A CAAS charm to deploy grafana for metrics visualization
-- [kafka k8s](https://jaas.ai/u/charmed-osm/kafka-k8s): A CAAS charm to deploy Kafka used as a messaging bus between OSM components
+- [kafka k8s](https://charmhub.io/kafka-k8s): A CAAS charm to deploy Kafka used as a messaging bus between OSM components
- [lcm](https://jaas.ai/u/charmed-osm/lcm/0): A CAAS charm to deploy OSM's Lifecycle Management (LCM) component responsible for network services orchestration.
- [mariadb k8s](https://jaas.ai/u/charmed-osm/mariadb-k8s): A Juju charm deploying and managing database server (MariaDB) on Kubernetes
- [mon](https://jaas.ai/u/charmed-osm/mon/0): A CAAS charm to deploy OSM's Monitoring Interface (MON) responsible for metrics collection
You can directly contact the team:
-- David GarcĂa ([david.garcia@canonical.com](david.garcia@canonical.com))
-- Eduardo Sousa ([eduardo.sousa@canonical.com](eduardo.sousa@canonical.com))
-- Mark Beierl ([mark.beierl@canonical.com](mark.beierl@canonical.com))
-- Guillermo Calvino ([guillermo.calvino@canonical.com](guillermo.calvino@canonical.com))
-- Wajeeha Hamid ([wajeeha.hamid@canonical.com](wajeeha.hamid@canonical.com))
+-
\ No newline at end of file
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
+name: osm-ha
+bundle: kubernetes
description: |
**A high-available Charmed OSM cluster**
- Highly Available and resilient against failures
- Supported with Ubuntu Advantage
- Availability of managed services
-bundle: kubernetes
applications:
zookeeper:
- charm: "cs:~charmed-osm/zookeeper-1"
- channel: "stable"
+ charm: zookeeper-k8s
+ channel: latest/edge
scale: 3
- series: kubernetes
storage:
- database: 100M
- options:
- zookeeper-units: 3
+ data: 100M
annotations:
gui-x: 0
gui-y: 500
- mariadb-k8s:
- charm: "cs:~charmed-osm/mariadb-k8s"
- channel: "stable"
+ kafka:
+ charm: kafka-k8s
+ channel: latest/edge
+ scale: 3
+ trust: true
+ storage:
+ data: 100M
+ annotations:
+ gui-x: 0
+ gui-y: 250
+ mariadb:
+ charm: charmed-osm-mariadb-k8s
scale: 3
series: kubernetes
storage:
annotations:
gui-x: -300
gui-y: -250
- kafka:
- charm: "cs:~charmed-osm/kafka-1"
- channel: "stable"
- scale: 3
- series: kubernetes
- storage:
- database: 100M
- options:
- zookeeper-units: 3
- kafka-units: 3
- annotations:
- gui-x: 0
- gui-y: 250
mongodb:
- charm: ch:mongodb-k8s
+ charm: mongodb-k8s
+ channel: latest/stable
scale: 3
series: kubernetes
storage:
gui-x: 0
gui-y: 0
nbi:
- charm: "cs:~charmed-osm/nbi-18"
+ charm: osm-nbi
+ channel: latest/edge
scale: 3
series: kubernetes
options:
database_commonkey: osm
auth_backend: keystone
log_level: DEBUG
+ resources:
+ image: opensourcemano/nbi:11.0.1
annotations:
gui-x: 0
gui-y: -250
ro:
- charm: "cs:~charmed-osm/ro-10"
+ charm: osm-ro
+ channel: latest/edge
scale: 3
series: kubernetes
options:
log_level: DEBUG
+ resources:
+ image: opensourcemano/ro:11.0.1
annotations:
gui-x: -300
gui-y: 250
ng-ui:
- charm: "cs:~charmed-osm/ng-ui-25"
+ charm: osm-ng-ui
+ channel: latest/edge
scale: 3
series: kubernetes
+ resources:
+ image: opensourcemano/ng-ui:11.0.1
annotations:
gui-x: 600
gui-y: 0
lcm:
- charm: "cs:~charmed-osm/lcm-15"
+ charm: osm-lcm
+ channel: latest/edge
scale: 3
series: kubernetes
options:
database_commonkey: osm
log_level: DEBUG
+ resources:
+ image: opensourcemano/lcm:11.0.1
annotations:
gui-x: -300
gui-y: 0
mon:
- charm: "cs:~charmed-osm/mon-12"
+ charm: osm-mon
+ channel: latest/edge
scale: 1
series: kubernetes
options:
database_commonkey: osm
log_level: DEBUG
keystone_enabled: true
+ resources:
+ image: opensourcemano/mon:11.0.1
annotations:
gui-x: 300
gui-y: 0
pol:
- charm: "cs:~charmed-osm/pol-10"
+ charm: osm-pol
+ channel: latest/edge
scale: 3
series: kubernetes
options:
log_level: DEBUG
+ resources:
+ image: opensourcemano/pol:11.0.1
annotations:
gui-x: -300
gui-y: 500
pla:
- charm: "cs:~charmed-osm/pla-13"
+ charm: osm-pla
+ channel: latest/edge
scale: 3
series: kubernetes
options:
log_level: DEBUG
+ resources:
+ image: opensourcemano/pla:11.0.1
annotations:
gui-x: 600
gui-y: -250
prometheus:
- charm: "cs:~charmed-osm/prometheus-9"
+ charm: osm-prometheus
+ channel: latest/edge
scale: 1
series: kubernetes
storage:
gui-x: 300
gui-y: 250
grafana:
- charm: "cs:~charmed-osm/grafana-10"
+ charm: osm-grafana
+ channel: latest/edge
scale: 3
series: kubernetes
annotations:
gui-x: 300
gui-y: 500
keystone:
- charm: "cs:~charmed-osm/keystone-16"
+ charm: osm-keystone
+ channel: latest/edge
scale: 1
- series: kubernetes
+ resources:
+ keystone-image: opensourcemano/keystone:releaseeleven-daily
annotations:
gui-x: 300
gui-y: -250
- - kafka:zookeeper
- zookeeper:zookeeper
- - keystone:db
- - mariadb-k8s:mysql
+ - mariadb:mysql
- - lcm:kafka
- kafka:kafka
- - lcm:mongodb
- nbi:nbi
- - mon:keystone
- keystone:keystone
- - - mariadb-k8s:mysql
+ - - mariadb:mysql
- pol:mysql
- - grafana:db
- - mariadb-k8s:mysql
+ - mariadb:mysql
--- /dev/null
+# Copyright 2022 Canonical Ltd.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+type: bundle
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
+name: osm
+bundle: kubernetes
description: |
**Single instance Charmed OSM**
- Stable and secure
- Supported with Ubuntu Advantage
- Availability of managed services
-bundle: kubernetes
applications:
zookeeper:
- charm: "cs:~charmed-osm/zookeeper-1"
+ charm: zookeeper-k8s
+ channel: latest/edge
scale: 1
- series: kubernetes
storage:
- database: 100M
+ data: 100M
annotations:
gui-x: 0
gui-y: 500
- mariadb-k8s:
- charm: "cs:~charmed-osm/mariadb-k8s"
- channel: "stable"
+ kafka:
+ charm: kafka-k8s
+ channel: latest/edge
+ scale: 1
+ trust: true
+ storage:
+ data: 100M
+ annotations:
+ gui-x: 0
+ gui-y: 250
+ mariadb:
+ charm: charmed-osm-mariadb-k8s
scale: 1
series: kubernetes
storage:
annotations:
gui-x: -300
gui-y: -250
- kafka:
- charm: "cs:~charmed-osm/kafka-1"
- scale: 1
- series: kubernetes
- storage:
- database: 100M
- annotations:
- gui-x: 0
- gui-y: 250
mongodb:
- charm: ch:mongodb-k8s
+ charm: mongodb-k8s
+ channel: latest/stable
scale: 1
series: kubernetes
storage:
gui-x: 0
gui-y: 0
nbi:
- charm: "cs:~charmed-osm/nbi-18"
+ charm: osm-nbi
+ channel: latest/edge
scale: 1
series: kubernetes
options:
database_commonkey: osm
auth_backend: keystone
log_level: DEBUG
+ resources:
+ image: opensourcemano/nbi:11.0.1
annotations:
gui-x: 0
gui-y: -250
ro:
- charm: "cs:~charmed-osm/ro-10"
+ charm: osm-ro
+ channel: latest/edge
scale: 1
series: kubernetes
options:
log_level: DEBUG
+ resources:
+ image: opensourcemano/ro:11.0.1
annotations:
gui-x: -300
gui-y: 250
ng-ui:
- charm: "cs:~charmed-osm/ng-ui-25"
+ charm: osm-ng-ui
+ channel: latest/edge
scale: 1
series: kubernetes
+ resources:
+ image: opensourcemano/ng-ui:11.0.1
annotations:
gui-x: 600
gui-y: 0
lcm:
- charm: "cs:~charmed-osm/lcm-15"
+ charm: osm-lcm
+ channel: latest/edge
scale: 1
series: kubernetes
options:
database_commonkey: osm
log_level: DEBUG
+ resources:
+ image: opensourcemano/lcm:11.0.1
annotations:
gui-x: -300
gui-y: 0
mon:
- charm: "cs:~charmed-osm/mon-12"
+ charm: osm-mon
+ channel: latest/edge
scale: 1
series: kubernetes
options:
database_commonkey: osm
log_level: DEBUG
keystone_enabled: true
+ resources:
+ image: opensourcemano/mon:11.0.1
annotations:
gui-x: 300
gui-y: 0
pol:
- charm: "cs:~charmed-osm/pol-10"
+ charm: osm-pol
+ channel: latest/edge
scale: 1
series: kubernetes
options:
log_level: DEBUG
+ resources:
+ image: opensourcemano/pol:11.0.1
annotations:
gui-x: -300
gui-y: 500
pla:
- charm: "cs:~charmed-osm/pla-13"
+ charm: osm-pla
+ channel: latest/edge
scale: 1
series: kubernetes
options:
log_level: DEBUG
+ resources:
+ image: opensourcemano/pla:11.0.1
annotations:
gui-x: 600
gui-y: -250
prometheus:
- charm: "cs:~charmed-osm/prometheus-9"
+ charm: osm-prometheus
+ channel: latest/edge
scale: 1
series: kubernetes
storage:
gui-x: 300
gui-y: 250
grafana:
- charm: "cs:~charmed-osm/grafana-10"
+ charm: osm-grafana
+ channel: latest/edge
scale: 1
series: kubernetes
annotations:
gui-x: 300
gui-y: 500
keystone:
- charm: "cs:~charmed-osm/keystone-16"
+ charm: osm-keystone
+ channel: latest/edge
scale: 1
- series: kubernetes
+ resources:
+ keystone-image: opensourcemano/keystone:releaseeleven-daily
annotations:
gui-x: 300
gui-y: -250
- - kafka:zookeeper
- zookeeper:zookeeper
- - keystone:db
- - mariadb-k8s:mysql
+ - mariadb:mysql
- - lcm:kafka
- kafka:kafka
- - lcm:mongodb
- nbi:nbi
- - mon:keystone
- keystone:keystone
- - - mariadb-k8s:mysql
+ - - mariadb:mysql
- pol:mysql
- - grafana:db
- - mariadb-k8s:mysql
+ - mariadb:mysql
--- /dev/null
+# Copyright 2022 Canonical Ltd.
+#
+# Licensed under the Apache License, Version 2.0 (the "License");
+# you may not use this file except in compliance with the License.
+# You may obtain a copy of the License at
+#
+# http://www.apache.org/licenses/LICENSE-2.0
+#
+# Unless required by applicable law or agreed to in writing, software
+# distributed under the License is distributed on an "AS IS" BASIS,
+# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+# See the License for the specific language governing permissions and
+# limitations under the License.
+type: bundle
MODEL_NAME=osm
-# Latest bundles using old mongodb-k8s
-# OSM_BUNDLE=cs:osm-68
-# OSM_HA_BUNDLE=cs:osm-ha-54
-# The charm store does not support referencing charms from CharmHub,
-# therefore we will point to the local bundles until we migrate all
-# charms to CharmHub.
-OSM_BUNDLE=/usr/share/osm-devops/installers/charm/bundles/osm/bundle.yaml
-OSM_HA_BUNDLE=/usr/share/osm-devops/installers/charm/bundles/osm-ha/bundle.yaml
-TAG=11
+OSM_BUNDLE=ch:osm
+OSM_HA_BUNDLE=ch:osm-ha
+CHARMHUB_CHANNEL=11.0/edge
+unset TAG
function check_arguments(){
while [ $# -gt 0 ] ; do
function install_snaps(){
if [ ! -v KUBECFG ]; then
+ KUBEGRP="microk8s"
sudo snap install microk8s --classic --channel=${MICROK8S_VERSION}/stable
+ sudo usermod -a -G microk8s `whoami`
sudo cat /var/snap/microk8s/current/args/kube-apiserver | grep advertise-address || (
echo "--advertise-address $DEFAULT_IP" | sudo tee -a /var/snap/microk8s/current/args/kube-apiserver
- microk8s.stop
- microk8s.start
+ sg ${KUBEGRP} -c microk8s.stop
+ sg ${KUBEGRP} -c microk8s.start
)
- sudo usermod -a -G microk8s `whoami`
mkdir -p ~/.kube
sudo chown -f -R `whoami` ~/.kube
- KUBEGRP="microk8s"
sg ${KUBEGRP} -c "microk8s status --wait-ready"
KUBECONFIG=~/.osm/microk8s-config.yaml
sg ${KUBEGRP} -c "microk8s config" | tee ${KUBECONFIG}
fi
if [ -v BUNDLE ]; then
- juju deploy -m $MODEL_NAME $BUNDLE --overlay ~/.osm/vca-overlay.yaml $images_overlay $extra_overlay
+ juju deploy --trust --channel $CHARMHUB_CHANNEL -m $MODEL_NAME $BUNDLE --overlay ~/.osm/vca-overlay.yaml $images_overlay $extra_overlay
else
- juju deploy -m $MODEL_NAME $OSM_BUNDLE --overlay ~/.osm/vca-overlay.yaml $images_overlay $extra_overlay
+ juju deploy --trust --channel $CHARMHUB_CHANNEL -m $MODEL_NAME $OSM_BUNDLE --overlay ~/.osm/vca-overlay.yaml $images_overlay $extra_overlay
fi
if [ ! -v KUBECFG ]; then
function generate_images_overlay(){
echo "applications:" > /tmp/images-overlay.yaml
- charms_with_resources="nbi lcm mon pol ng-ui ro pla keystone"
+ charms_with_resources="nbi lcm mon pol ng-ui ro pla"
for charm in $charms_with_resources; do
cat << EOF > /tmp/${charm}_registry.yaml
registrypath: ${REGISTRY_URL}opensourcemano/${charm}:$TAG
resources:
image: /tmp/${charm}_registry.yaml
+EOF
+ done
+ ch_charms_with_resources="keystone"
+ for charm in $ch_charms_with_resources; do
+ cat << EOF > /tmp/${charm}_registry.yaml
+registrypath: ${REGISTRY_URL}opensourcemano/${charm}:$TAG
+EOF
+ if [ ! -z "$REGISTRY_USERNAME" ] ; then
+ echo username: $REGISTRY_USERNAME >> /tmp/${charm}_registry.yaml
+ echo password: $REGISTRY_PASSWORD >> /tmp/${charm}_registry.yaml
+ fi
+
+ cat << EOF >> /tmp/images-overlay.yaml
+ ${charm}:
+ resources:
+ ${charm}-image: /tmp/${charm}_registry.yaml
+
EOF
done