Upgrading Docker containers

Hello!
I need some guidance on how to upgrade a current Opensearch installation running in Docker, from 1.0.1 to 2.18.

This includes Dashboards and Logstash containers as well. Here is where it gets tricky. There have been no need for Opensearch until now, but the project originally started three years ago, and I can see the images have been created three years back. A few months ago, it has been used successfully for a demo, and therefore we’d like to keep configurations and our index.

From my research into the system, it looks like it has been originally installed from a docker-compose file, as I see a single node for Opensearch, Opensearch-Dashboards and Logstash configurations in this compose-file.
Compose-file is as follows:

version: '3'
services:
  opensearch-node1:
    image: opensearchproject/opensearch:1.0.1
    container_name: opensearch-node1
    environment:
      - cluster.name=opensearch-cluster
      - node.name=opensearch-node1
      - discovery.seed_hosts=opensearch-node1
      - discovery.type=single-node
      - bootstrap.memory_lock=true # along with the memlock settings below, disables swapping
      - "OPENSEARCH_JAVA_OPTS=-Xms512m -Xmx512m" # minimum and maximum Java heap size, recommend setting both to 50% of system RAM
    ulimits:
      memlock:
        soft: -1
        hard: -1
      nofile:
        soft: 65536 # maximum number of open files for the OpenSearch user, set to at least 65536 on modern systems
        hard: 65536
    volumes:
      - opensearch-data1:/usr/share/opensearch/data
    ports:
      - 9200:9200
      - 9600:9600 # required for Performance Analyzer
    networks:
      - opensearch-net
    restart: unless-stopped
  opensearch-dashboards:
    image: opensearchproject/opensearch-dashboards:1.0.1
    container_name: opensearch-dashboards
    ports:
      - 5601:5601
    expose:
      - "5601"
    environment:
      OPENSEARCH_HOSTS: '["https://opensearch-node1:9200"]' # must be a string with no spaces when specified as an environment variable
    networks:
      - opensearch-net
    restart: unless-stopped
  logstash:
    image: opensearchproject/logstash-oss-with-opensearch-output-plugin:7.16.2
    container_name: logstash
    ports:
      - "5044:5044/tcp" 
      - "5514:5514/udp"
    networks:
      - opensearch-net
    volumes:
      - /var/dockerfiles/logmgnt/demotest.yml:/usr/share/logstash/config/demotest.conf
      - /var/dockerfiles/logmgnt/pipelines.yml:/usr/share/logstash/config/pipelines.yml
    stdin_open: true
    tty: true
    restart: unless-stopped
   
volumes:
  opensearch-data1:


networks:
  opensearch-net:

My question is: How should we update? I went through the documentation for doing a rolling-upgrade, but I’m a little unsure if it fits my case, because of the compose-file?
Would the easiest be to just start completely over?

If you choose the upgrade route - one more thing to keep in mind is the Compatibility, more info here (you would have to upgrade a few times to get from 1.0.1 to 2.18): Upgrading OpenSearch - OpenSearch Documentation

If starting fresh is an option, that might be a better path for you.

best,
mj